Git Product home page Git Product logo

Comments (2)

zemian avatar zemian commented on May 17, 2024 1

Ah, I see it works with your updated config now. Thanks!

Yes, updating the example config in your site's link (the one show at the bottom of your home page. eg: https://play.tailwindcss.com/RcIZd1Mwho) would be good for beginners so they don't think it's broken.

BTW, I think DaisyUI is a pretty cool project! I feel the the Tailwind can be pretty verbose on styling common UI components, and DaisyUI's built-in schematic role names make it easier to get started and be productive. I like how I can further customize the UI with direct Tailwind utility classes! This is pretty awesome. Keep up the good work!

from daisyui.

saadeghi avatar saadeghi commented on May 17, 2024

Hi, You need to add colors to the config this way

module.exports = {
  plugins: [
    require('daisyui'),
  ],
  theme: {
    extend: {
      colors: require('daisyui/colors')
    },
  },
}

Reason:
DaisyUI adds colors to Tailwind if it finds tailwindcss installed as a dependency, If it can't find tailwindcss, it shows a warning on console, telling you how to extend color (like the code above)
You can't see the console log in Tailwind Play unless you open the browser console tho 😅
This functionality allows us to import colors by default, but if you don't have the tailwindcss installed as a dependency (if you're using a fork or a similar project with different name) you can still use the colors.

I will update the Tailwind Play example link in the docs. Thanks!

from daisyui.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.