Show dev: Flowbite Svelte - Open-source UI component library
Tags: svelte, tailwindcss, flowbite, showdev
Published: 2023-04-27 10:38:27

[Flowbite Svelte](https://flowbite-svelte.com/) is a free and open-source UI component library based on the core Flowbite components and built with native Svelte components and interactivity handling.

This library features hundreds of interactive elements such as navbars, dropdowns, modals, and sidebars all handled by Svelte and based on the utility classes from Tailwind CSS.

## Getting started

Learn how to get started with Flowbite Svelte by following the [quickstart guide](https://flowbite-svelte.com/docs/pages/introduction) and start leveraging the interactive Svelte components coupled with Flowbite and Tailwind CSS.

[![Svelte UI component library](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/oyt8usq5o1ipx843wbd1.png)](https://flowbite-svelte.com/docs/pages/introduction)

### Using SvelteKit

You can install SvelteKit or Svelte to start your app. For SvelteKit:

```
npm create svelte@latest my-app
cd my-app
npm install
```

### Using Svelte

If you want to get started with Svelte:

```
npm create vite@latest myapp -- --template svelte
cd myapp
npm install
```

### Install Tailwind CSS

In order to enable the utility classes from Tailwind CSS install the package using NPM:

```
npx svelte-add@latest tailwindcss
npm i
```

Run a local development server by running:

```
npm run dev
```

### Install Flowbite Svelte

Run the following command to install all Flowbite dependencies and libraries:

```
npm i flowbite flowbite-svelte classnames @popperjs/core
```

### Configuration

Update the `tailwind.config.cjs` file from your root project folder to let the Tailwind CSS compiler know where to look for the utility classes and also set up the Flowbite plugin.

```
const config = {
  content: [
    "./src/**/*.{html,js,svelte,ts}",
    "./node_modules/flowbite-svelte/**/*.{html,js,svelte,ts}",
  ],

  theme: {
    extend: {},
  },

  plugins: [
    require('flowbite/plugin')
  ],
  darkMode: 'class',
};

module.exports = config;
```

That's it! Now you should be able to work with the Flowbite Svelte library and import components such as the navbar, dropdown, modal, and more.

## Svelte

[Svelte](https://svelte.dev/) is a modern and growing front-end compiler. Developers build boilerplate-free components using languages HTML, CSS and JavaScript. Svelte compiles your code to tiny, framework-less vanilla JS.

## Tailwind CSS

Flowbite Svelte leverages the utility classes from the popular [Tailwind CSS](https://tailwindcss.com) framework allowing greater customization capabilities directly from a component level in Svelte.

## Flowbite Ecosystem

[Flowbite](https://flowbite.com) is also available in other frameworks such as vanilla JS with HTML, React, Vue, Angular, and even integration possibilities with back-end frameworks such as Laravel, Django, Flask, and Phoenix.

Check out the main [GitHub repository](https://github.com/themesberg/flowbite) to explore other libraries too as well as the [Figma design system](https://flowbite.com/figma/).

## UI Components

[Flowbite Svelte](https://flowbite-svelte.com/) has a rich collection of commonly used components coded with Svelte that leverage the utility classes from Tailwind CSS and you can check out the full list of components by navigating through the components section in the sidebar on the left side of the page.

## Contributing

Flowbite Svelte is a free and open-source UI component library built with Svelte native components and based on the Flowbite ecosystem and contributions are more than welcome.

Check out [contributing guide](/docs/pages/how-to-contribute) to learn how you can be a part of the open-source community.

## License

Flowbite Svelte is a free and open-source UI component library licensed under the [MIT License](https://github.com/themesberg/flowbite-svelte/blob/main/LICENSE).