Giter Club home page Giter Club logo

component-styleguide's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

component-styleguide's Issues

Menu broken in Firefox

screen shot 2015-11-23 at 11 02 05 am

It's functional but clunky when using the pattern library navigation in the latest version of Firefox (OSX)

Ability to define default data source

It would be helpful to have a place to define default data, for partials that have not been given a context. i.e. given the following template:

<h1>{{ headingText }}</h1>

and the following data (possibly in a data/data.json file, or in a location defined in the configuration options):

{
    "headingText": "This is a heading"
}

the following would result:

<h1>This is a heading</h1>

Having such a function would mean authors could avoid scenarios where templates need to be written as such:

<h1>{{#if headingText}}{{headingText}}{{else}}This is a heading{{/if}}</h1>

Possible to nest components?

I tried to nest a component (say components > atoms > buttons > button.html button-secondary.html etc) and the menu properly displayed Button/Button and Button/Button Secondary, however you're met with a "File not found" message when trying to navigate.

Ideally you have a way to group components, and simplify the browsing experience to navigate to grouped components.

If a static resource begins with http(s), don’t prepend staticPath

I’m trying to add live reload functionality. To do so, I’ve added a command to my build script to start livereload server on port 9091. Of course, I then need to link to the livereload.js script. So I did the following in index.js:

var styleguide = require('component-styleguide'),
    path = require('path');

styleguide({
    components: path.resolve(__dirname, 'components'),
    ext: 'html',
    data: path.resolve(__dirname, 'data'),
    staticLocalDir: path.resolve(__dirname, 'compiled'),
    staticPath: '/compiled',
    stylesheets: ['app.css'],
    scripts: ['http://localhost:9091','app.js']
});

Unfortunately, this generates the following HTML:

<script src="/compiled/http://localhost:9091"></script>
<script src="/compiled/app.js"></script>

I tried changing staticPath: to '', and add this path to each stylesheet and script individually, but this had no effect. Adding a resource to the scripts or stylesheets arrays that starts with http:// or https://, the staticPath value should be ignored… unless there is another way of achieving the desired result?

Example setup won't compile

Hi there,

Thanks for putting this together. I really love the simplicity of if, but your example setup won't compile (everything works - scss, js, but not the styleguide).

I am running on Win, Node V4.4.5, and npm 3.5.2.,but when I run node index.js on the root folder I see
Styleguide server started at http://:::3000 on the terminal, but nothing gets compiled to compiledfolder.

Styleguide server started at http://:::3000

Tiny bug, but seen on two separate instances (one Mac OS X, one on Windows). When the server starts, it reports as running on http://:::3000. Should this not report http://localhost:3000 instead?

Live reload functionality

I noticed that the component styleguide package depends on the express server, I was trying to set up gulp processes to automatically refresh the server when a change is detected to the component or style directory. I was looking to see if there was a method to shoot a refresh of to the server without having to install another package.

Component menus unusable when taking up too much vertical space

I am working on a styleguide that has around 34 items in the "atoms" component folder. When on a laptop screen a decent amount of these items get cut off of the list and I am unable to navigate to them using the menu.

You cannot scroll the page while in the menu.

screen shot 2015-11-04 at 3 25 08 pm

Generic Structure

Hey Lars, I like the generic, unopinionated, feel of this and wonder how easy it would be to make this more generic. Would it be a lot of work to lose the requirement of an 'atomic' structure or add a new category of 'generic' components?

Although I like the PatternLab structure of 'atoms', 'molecules', 'organisms', 'pages' etc. not all (existing) projects are a great fit. For those I'd like to have, say, a generic '/components' folder in which I could place generic components (nested subfolders).

Static version?

Being able to build a static version to include in the codebase would be useful for QA, consumption outside of running the local server, etc.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.