Source Carousel
Table of contents
Installation
NPM
npm i @ppci/source-carousel
// Polyfill: https://lit-element.polymer-project.org/guide/use#polyfills
npm i --save-dev @webcomponents/webcomponentsjs
Usage
Javascript
import '@ppci/source-carousel';
Browser
<!-- Default -->
<script type="module" src="https://cdn.jsdelivr.net/npm/@ppci/source-carousel/builds/index.min.js" />
<!-- Legacy -->
<script type="module" src="https://cdn.jsdelivr.net/npm/@ppci/source-carousel/builds/legacy.min.js" />
<!-- Component -->
<source-carousel
.sources=${Array}
@onClose=${Function}
></source-carousel>
Properties
Property | Type | Description | Possible Values |
sources | Array | List with sources | ``` [ { name: String, city: String, image: String, }, ] ``` |
Events
Name | Description | Payload |
@onClose | When close button is clicked |