Instantly share code, notes, and snippets.
dark:\w+([-:\w]*\w)
[^'"\s]*dark:[^'"\s]*
Thanks to @angus-mcritchie
This regex doesn't include more complex dark classes with prefixes like [&[data-test]]:dark:text-white here is a regex example. For those who are looking to match those as well, you can try [^'"\s]*dark:[^'"\s]* here is the regex example.
This regex doesn't include more complex dark classes with prefixes like [&[data-test]]:dark:text-white here is a regex example.
[&[data-test]]:dark:text-white
For those who are looking to match those as well, you can try [^'"\s]*dark:[^'"\s]* here is the regex example.
Thank you so much @angus-mcritchie ❤️ This gist is quite old which is why the complex dark mode classes aren't working...
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Thank you so much @angus-mcritchie ❤️
This gist is quite old which is why the complex dark mode classes aren't working...