Your Web News in One Place

Help Webnuz

Referal links:

Sign up for GreenGeeks web hosting
March 26, 2022 12:51 am GMT

Setting up TailwindCSS with SASS in RedwoodJS

Here's a quick and easy guide on how to setup TailwindCSS, using the SASS preprocessor, in a new RedwoodJS project.

Requirements

Make sure you have the correct npm / yarn versions installed, the details of which can be found at https://redwoodjs.com/docs/quick-start.

Setting up tailwind and scss

yarn create redwood-app my-app-namecd my-app-nameyarn rw setup ui tailwindyarn rw setup webpackyarn workspace web add -D sass sass-loader

The code above will create a new RedwoodJS project, then set up Tailwind, webpack, and Sass in your project.

Make sure to change index.css to index.scss and update the import in your web/src/App.js file.

Conclusion

That should be it! You're now all set to go :)


Original Link: https://dev.to/klickers/setting-up-tailwindcss-with-sass-in-redwoodjs-5am

Share this article:    Share on Facebook
View Full Article

Dev To

An online community for sharing and discovering great ideas, having debates, and making friends

More About this Source Visit Dev To