Package Exports
- rating-custom-element
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (rating-custom-element) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
rating-custom-element
🏂 Rating Custom Element
Intended as plug and play HTML element to enable custom rating. Styling is left completely to the end user. For in-browser usage.
View demo.
Installation
Available via npm:
npm i rating-custom-element
Usage
Include rating-element.js
to your html or import "rating-custom-element"
if installed via npm.
Add x-rating-element
html element to your dom on the place where you wish to have a rating element.
Options:
- value - initial value [default: 0]
- number - number of rating elements [default: 5]
- default-class - class name for rank elements [default: x-rating]
- marked-class - class name added to selected rank elements [default: x-marked]
License
MIT.