Themer / get-started/installation

Installation

Learn how to install Tailus Themer and all its dependancies in your project.

Prerequisites

Before you begin, ensure that you have already installed Tailwind CSS in your project. If not, please follow the Tailwind CSS installation guide.

1. Install the themer package

Run the following command in your terminal to install the Tailus Themer package in your project:

npm install @tailus/themer

This command will add the @tailus/themer package to your project’s dependencies.

2. Import and use the themer plugin

After installing the Themer package, import and use the themer plugin in your Tailwind CSS configuration file:

import themer from "@tailus/themer";

export default = {
    content : [
        // ... your other paths here
        "./node_modules/@tailus/themer-**/dist/**/*.{js,ts}"
    ],
    theme: {
        extend: {},
    },
    plugins: [
        themer
    ],
};
    
    

In this code snippet, the themer plugin is imported at the top of the file. Then, the path to the Themer packages is added to the content array, and the themer plugin is added to the plugins array in your Tailwind CSS configuration file.

3. Install components Themer packages

Install the Themer packages for the components you want to use in your project. For example, if you want to use the Form component, install the @tailus/themer-form package.

To learn more about a component’s Themer package, see its documentation.