Configuration

Nature UI is based on tailwindcss which means you can apply every tailwindcss configuration pattern to which mostly requires a tailwind.config.js file and this is mandatory.

A more basic tailwind.config.js file should look like:

// tailwind.config.js
module.exports = {
purge: [],
theme: {
extend: {},
},
variants: {
extend: {},
},
plugins: [],
};

You will find a detailed guide on how to configure

tailwindcss on tailwindcss official website.

Purging unused css#

Tailwind comes with an option to remove unused css. Include a relative path to @nature-ui installation:

// tailwind.config.js
module.exports = {
purge: [
+ './node_modules/@nature-ui/**/*.js'
],
theme: {
extend: {},
},
variants: {
extend: {},
},
plugins: [
+ './node_modules/@nature-ui/**/*.js'
],
};