DEV Community

Toma
Toma

Posted on

1

Light and Dark Theme for your 2020 Web Site

How web sites should look like and behave is constantly evolving. For the past year or two - having light and dark themes is the norm. Otherwise, you are not adapting to the user. Otherwise you (and also I) are lazy developer.
Here is the basic CSS for theming:

@media (prefers-color-scheme: dark) {
//dark background, light colors for text, icons and images
}
@media (prefers-color-scheme: light) {
//light background, dark colors for text, icons and images
}

Here is a work in progress - applying themes for a WP site:
https://programtom.com/common_sense/
Sadly, it will not work on any other theme or most other Web Sites, because of the specific CSS rules that must be overwritten.

Sentry blog image

How to reduce TTFB

In the past few years in the web dev world, we’ve seen a significant push towards rendering our websites on the server. Doing so is better for SEO and performs better on low-powered devices, but one thing we had to sacrifice is TTFB.

In this article, we’ll see how we can identify what makes our TTFB high so we can fix it.

Read more

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more