As a website, you will inevitably encounter customer requirements to switch the color of the website. Although this is not a very biased requirement, I have never done this. Recently, I encountered this kind of requirement when I made a website. Although the process was smooth, I still want to record it for my reference.
Color switching is similar to Web chat tools. No matter what technology is used to achieve color switching, the final principle is nothing more than focusing on the choice of the control side: Let the server side to complete this thing, or let the client to complete this thing.
Contact your current situation. Because the server is a purchased product and cannot perform more operations, the control end of the color switch is placed on the browser. Let the browser record the user's color to load different styles, so as to achieve the purpose of switching the color.
I also want to smile a bit. Isn't it a combination of the "pull" concept in web communication? Isn't it a "pull" chat principle rebuild?
This is the case.