# Smelte
[](https://img.shields.io/npm/l/smelte.svg)
[](https://img.shields.io/npm/dm/smelte.svg)
[](https://img.shields.io/npm/v/smelte.svg)
[](https://discord.gg/nZc64MMdkU)
[Demo](http://smeltejs.com/)
Smelte is a UI framework built on top of Svelte and Tailwind CSS using Material Design spec (hence the name).
It comes with many components and utility functions making it easy to build beautiful responsive layouts while keeping
bundle size and performance at check all thanks to Svelte.
### Installation
To get you started you need to add Smelte to your dependencies with your favorite package manager
```
$ npm install smelte
```
or
```
$ yarn add smelte
```
Then add the Smelte Rollup plugin (after svelte but before css). Webpack support coming soon.
```js
const smelte = require("smelte/rollup-plugin-smelte");
plugins = [
...your plugins,
smelte({
purge: production,
output: "public/global.css", // it defaults to static/global.css which is probably what you expect in Sapper
postcss: [], // Your PostCSS plugins
whitelist: [], // Array of classnames whitelisted from purging
whitelistPatterns: [], // Same as above, but list of regexes
tailwind: {
theme: {
extend: {
spacing: {
72: "18rem",
84: "21rem",
96: "24rem"
}
}
}, // Extend Tailwind theme
colors: {
primary: "#b027b0",
secondary: "#009688",
error: "#f44336",
success: "#4caf50",
alert: "#ff9800",
blue: "#2196f3",
dark: "#212121"
}, // Object of colors to generate a palette from, and then all the utility classes
darkMode: true,
}, // Any other props will be applied on top of default Smelte tailwind.config.js
}),
]
```
Then you should add Tailwind utilites CSS in your app component.
```js
import "smelte/src/tailwind.css";
```
You might also need to include material icons in your template's