olivetree Posted October 31 Share Posted October 31 (edited) Hi How to use site-rockfrontend tailwind css with site-rockend without having npm to gerate tailwindcss on a external webhoster? Just install the site-profile does not solve this, I suppose. I understood that npm is needed to generate the tailwind.css on a local dev box and put that then up to the external site. That makes sense. I just want to understand how to use tailwindcss in that combination without having npm locally and on the external site? Is that possible? Edited November 8 by olivetree Link to comment Share on other sites More sharing options...
bernhard Posted November 1 Share Posted November 1 Hey @olivetree my site profile uses NPM to install tailwind and tailwind is used for all the utility classes like "mt-5" or "py-2" etc.; Whenever you run "npm run build" this process is started and it creates a css file that you can then load on your webpage. In my profile this is usually done whenever a file changes (from /site/livereload.php). If you don't modify your markup on your production system this file will never ever change, so you can just upload that file and that's all you have to do. If you don't need to recompile the file you don't need npm on the remote server. 1 Link to comment Share on other sites More sharing options...
olivetree Posted November 1 Author Share Posted November 1 (edited) Many thanks @bernhard. Now I understand the mechanism behind. I didnt realized that this way changes are collected and rebuild into tailwinds css file(s). Edited November 1 by olivetree grammatical adjustment 1 Link to comment Share on other sites More sharing options...
Ivan Gretsky Posted November 1 Share Posted November 1 In case you really need to build tailwindcss without node and running npm install for whatever reason you can use this https://tailwindcss.com/blog/standalone-cli. Just download a binary, put it somewhere and call with proper arguments. To make it easy in VS Code create a task. 1 Link to comment Share on other sites More sharing options...
olivetree Posted November 1 Author Share Posted November 1 Many thanks for your hint @Ivan Gretsky, indeed this is an appraoch without having npm installed. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now