darkreader / darkreader/darkreader

[Bug] FOUC/FOUT on some websites

Open
#14,165 2 comments 3 reactions 0 assignees View on GitHub
bug
Dominant language
TypeScript
Stars
22.4k
Forks
2.7k
Avg merge
21h 11m
Merged PRs (30d)
78

Description

### Prerequisites

- [x] I [searched for any existing report](https://github.com/darkreader/darkreader/issues?q=is%3Aissue) about this bug to avoid opening a duplicate.
- [x] I can reproduce this bug in a new, unmodified web browser profile with Dark Reader installed as the only extension.
- [x] I understand I need to use the [Broken Website Report template](https://github.com/darkreader/darkreader/issues/new?assignees=&labels=Broken+Website&template=broken-website-report.yml&title=%5BBroken+Website%5D+Replace+with+title) if this bug I am reporting occurs on a single website.

### Bug Description

A FOUC/FOUT occurs when you visit the website below the first time (best seen with a new profile or in incognito mode) with the extension enabled.

Additional website to test https://www.openstreetmap.at/.

Edit: Actually even my own website behaves like that! It has dark mode by default.

### Website Address

https://www.psypost.org/agnostics-are-more-indecisive-neurotic-and-prone-to-maximizing-choices-distinguishing-them-from-atheists-and-christians/

### Steps To Reproduce

Just open the link and observe the behaviour.

### Expected Behavior

No FOUC/FOUT

### Actual Behavior

FOUC/FOUT that lasts a second

### Screenshots

_No response_

### Operating System

Linux

### Web Browser name and version

Firefox 137.0.1

### Dark Reader version

4.9.103

### Additional Context

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.