Tailwind css integration in hubspot and into react components

Hello all

I been recently getting up to speed with tailwind and react idependly of hubspot. I tried to see if there were resoucres into firstly looking into react elements using the hubspot boilerplate theme - is it possible for a video workthrough demonstrating the correct techniques. I have eventually figured the fact we have two different workflows where the react elements are build and uploaded into the development project section (which tab I finding impossible to find in beta version of Hubspot!) and the hubspot themeing follows the normal hs upload flow (if we working locally). I am currently trying to use the boilerplate and then adapt it to see if can use additional react libaries such as framer motion.
Would be great to see web specific examples of react elements - the example I found all seem to relate to admin cards.
The other thing I am also looking at is tailwind .css - which i getting issues with- i discovered the blog entry on the subject - i following whats suggested but i may be missing a detail.

I understand the preprocessor script eg

npx tailwindcss -i ./src/input.css -o ./dist/output.css --watch

looks locally for files with certain extensions in certains. this is my file structure

here the path suggested in the blog

And you run a preprocessor watch script to look for which files to generates an output.css with the styles used - unfortunately it may be the file structure is different to the example giving the output file remains empty.

Also the blog doesn’t seem to suggest linking to the output file to base template theme

{{ require_css(get_asset_url(“../../dist/output.css”)) }}

Any suggestions would kindly recieved.

My eventuall goal is eventually getting tailwind to preprocess on the entire theme file and then the react file

Many thanks for any suggesitions

@simonfigma23 if you’re interested in tailwind CSS, you might try this boilerplate as a starting point instead:

https://github.com/freshjuice-dev/freshjuice-hubspot-theme

Many thanks Jennifer your github respository works brilliantly.

I gone through my tailwind installation, by looking at a simpler installation so i can see what the config paths should be - think I got my path sorted now

happy to help @simonfigma23, to clarify, this wasn’t my github repo, just one I’ve used and has been shared in the dev community. I’m glad you were able to find the best path forward!