Tailwindcss, WordPress·

Install DaisyUI in WordPress

Quick guide to get DaisyUI installed in your WordPress theme!

How install DaisyUI in WordPress

Let's look at how to install DaisyUI in your WordPress theme. This is an easy process and we will go through all the steps needed!

Download starter theme (optional)

The first thing we need to do is get our WordPress theme. I personally like to do this by downloading a starter theme from underscores.me, but if you want to create your own fresh theme this is fine to do. Once you have your theme ready, open it up in your code editor.

Install TailwindCSS

We now need to install TailwindCSS in our WordPress theme. This is a case of following the instructions on the TailwindCSS website. A full guide on how to do this can be found here.

Install DaisyUI

Now we are at the point where we can actually install DaisyUI into our WordPress theme! Instructions can be found here, but its very simple. You run the following command in the route of your WordPress theme:

terminal
npm i -D daisyui@latest

Next, you need to add daisyui to your tailwind config file's plugins array, like this:

tailwind.config.js
module.exports = {
    //...
    plugins: [require("daisyui")],
}

And that's it! You are now set up and ready to start using DaisyUI. I told you it was easy!

Comments

No comments yet.

Be the first to share your thoughts!

Join the discussion