Obfuscate CSS classes
Unanswered
Sage Thrasher posted this in #help-forum
Sage ThrasherOP
Using TailwindCSS with NextJS v14, I would like to obfuscate the tailwind css class names (like Discord does in the attachment below) to help tackle web scraping and simply additional protection to my design (making it harder for anyone to take) although the priority is web scraping because my website is an index which would get used quite frequently.
5 Replies
West African Lion
For most of the website where the css classes look obfuscated is because they use libraries like styled-components or emotion, it’s because it generates the css classes automatically. It’s not because they want to obfuscate it
^, also obfuscating won't help at all. the crawler can just look up the css declaration of your
and css is just for styling. crawlers crawl to get textual content, they don't really care about whether your cta button background colour is #482a2b or #a83b24.
css obfuscation doesn't help with anything.
.obfuscated-class, if it sees { color: red } it knows the original name of .obfuscated-class is text-[red] or something similar.and css is just for styling. crawlers crawl to get textual content, they don't really care about whether your cta button background colour is #482a2b or #a83b24.
css obfuscation doesn't help with anything.
even tho the statements above are true, if you still want to do the obfuscation then this repo might be worth checking out:
https://github.com/soranoo/next-css-obfuscator/
https://github.com/soranoo/next-css-obfuscator/
Its also worth noting that its not exactly legal to copy someone elses websites, so if someone does copy your website you could get them into legal problems.
https://www.google.com/search?client=firefox-b-d&q=+copyright+law
https://www.google.com/search?client=firefox-b-d&q=Intellectual+Property
You could also add a license to the website/project/repo.
https://www.google.com/search?client=firefox-b-d&q=+copyright+law
https://www.google.com/search?client=firefox-b-d&q=Intellectual+Property
You could also add a license to the website/project/repo.
@Sage Thrasher If you dont need any more help, please mark a solution.