This guide will help you to use Flexilla in your new or existing ViteJS Project
Install via npm
-
Create a new Project
Create a new project if not having one.Shell
npm create vite@latest vite-example -- --template vanilla-ts cd vite-example
-
Install flexilla
-
Usage
script
import {Accordion, Tabs} from "@flexilla/flexilla" const accordion = new Accordion("#my-accordion") const tabs = new Tabs("#my-tabs",{ // options })
Using CDN
-
Import the library via CDN
src/main.ts
<script type="module"> import * as Flexilla from 'https://esm.run/@flexilla/flexilla'; </script>
-
Usage
index.html
<script type="module"> new Flexilla.Tabs("[data-tabs-el]") Flexilla.Accordion.AutoInit(".accordion-el") </script>
Quick Start Examples
Checkout these quick start examples to get a feel of Flexilla + ViteJS here