Home  >  Q&A  >  body text

How to test color changes on a website?

I want to replace 10 specific colors with new colors as per requirement (eg: #ddd replaced with #000. Different replacement like this). I just found and replaced over 300 places in all my css files. Now, want to test on the website whether all colors are replaced correctly. With over 300 places, it's hard to understand which color is used where. Is there any way to do this? Thanks

P粉032900484P粉032900484183 days ago260

reply all(1)I'll reply

  • P粉513318114

    P粉5133181142024-04-02 11:08:21

    If you mean to change one specific color to another specific color in your code. So there is an option in VS Code to search for a specific string and change to something else.

    Also, to prevent this - I recommend you to use CSS custom properties (variables).

    ---> https://developer.mozilla.org /en-US/docs/Web/CSS/Using_CSS_custom_properties

    reply
    0
  • Cancelreply