sg-example

Display example-code in styleguides


Keywords
laat, example, code-example, web-component, web-components, styleguide
License
MIT
Install
npm install sg-example@1.1.0

Documentation

sg-example

travis npm js-standard-style

A web component for displaying code examples in styleguides.

Maintained by Sigurd Fosseng.

Demo

Check it live.

Usage

<style>
    nav {
        border: 1px solid #ddd;
    }
    li {
        background-color: #fff;
        color: #f43;
    }
</style>
<sg-example>
    <nav>
        <ul>
            <li>example element 1</li>
            <li>example element 2</li>
        </ul>
    </nav>
</sg-example>

Gives this output:

example

Contributing

  1. Fork it!
  2. Create your feature branch: git checkout -b my-new-feature
  3. Commit your changes: git commit -m 'Add some feature'
  4. Push to the branch: git push origin my-new-feature
  5. Submit a pull request :D

License

MIT © Sigurd Fosseng