3.1.5 • Published 6 years ago
rosid-handler-components v3.1.5
rosid-handler-components
UI to help you build and document web components.
Install
npm install rosid-handler-components
Usage
API
const components = require('rosid-handler-components')
components('.html').then(console.log) // Returns HTML of the UI
components('.json').then(console.log) // Returns JSON for the UI
Rosid
Add the following object to your rosidfile.json
, rosidfile.js
or routes array. rosid-handler-components
will return the HTML of the UI or the JSON for the UI depending on the path.
{
"name" : "Components",
"path" : "ui/**/index.{html,html.json}",
"handler" : "rosid-handler-components"
}
Disable automatic page reloads for the UI to get realtime updates when developing components. You can do so by using the --static
or -s
option in the CLI or by using the static
option.
rosid serve src/ dist/ -s '/ui/index.html'
Rosid.serve('src/', { static: '/ui/index.html' }, (err) => {})
Parameters
filePath
{?*}
Fictive path that ends with.html
or.json
opts
{?Object}
Options.
Returns
{Promise<String|Buffer>}
HTML or JSON of the UI.
3.1.5
6 years ago
3.1.4
6 years ago
3.1.3
6 years ago
3.1.2
7 years ago
3.1.1
7 years ago
3.1.0
7 years ago
3.0.0
7 years ago
3.0.0-0
7 years ago
2.0.1
7 years ago
2.0.0
7 years ago
1.8.3
7 years ago
1.8.2
7 years ago
1.8.1
7 years ago
1.8.0
7 years ago
1.7.1
7 years ago
1.7.0
7 years ago
1.6.0
7 years ago
1.5.2
7 years ago
1.5.1
7 years ago
1.5.0
7 years ago
1.4.0
7 years ago
1.3.1
7 years ago
1.3.0
7 years ago
1.2.1
7 years ago
1.2.0
7 years ago
1.1.2
7 years ago
1.1.1
7 years ago
1.1.0
7 years ago
1.0.1
7 years ago
1.0.0
7 years ago