---
title: "Discussion on \"Add dark mode to your React application with TailwindCSS\" | Hashnode"
description: "Discussion on \"Add dark mode to your React application with TailwindCSS\". People expect dark mode your application. Keep on top of the game with Tailwind and its easy dark mode integration."
url: "https://hashnode.com/posts/add-dark-mode-to-your-react-application-with-tailwindcss/61041520805a765b08876fc8"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Add dark mode to your React application with TailwindCSS](https://juanzen.hashnode.dev/add-dark-mode-to-your-react-application-with-tailwindcss?utm_source=hashnode&utm_medium=feed)

People expect dark mode your application. Keep on top of the game with Tailwind and its easy dark mode integration.

Jul 30, 2021 · 5 min read · juanzen.hashnode.dev  
Read the article

-   [#reactjs](https://hashnode.com/tag/reactjs)
-   [#tailwind-css](https://hashnode.com/tag/tailwind-css)
-   [#tailwind-css-tutorial](https://hashnode.com/tag/tailwind-css-tutorial)
-   [#css](https://hashnode.com/tag/css)

## Written by

[Juan Alvarez](https://hashnode.com/@Juanzen)

@Juanzen · Miranda, VE

  
[View profile](https://hashnode.com/@Juanzen)

Frontend web developer

Front-end developer | React (Next.js)

## Responses 1

Markdown supported · ⌘↵ to post

[JOY SAM RAJ](https://hashnode.com/@JoySam)

[Jun 12, 2022](https://hashnode.com/posts/add-dark-mode-to-your-react-application-with-tailwindcss/61041520805a765b08876fc8/comment/62a5a7bba2c282d2d837b29a)

I guess change this line

`const [theme, setTheme] = useState(localStorage.getItem('theme'));`

Because while refreshes it overrides the local storage

[Shantun Parmar](https://hashnode.com/@shantun)

[Aug 2, 2021](https://hashnode.com/posts/add-dark-mode-to-your-react-application-with-tailwindcss/61041520805a765b08876fc8/comment/610774b033a2a43971a2f556)

very amazing article

[Juan Alvarez](https://hashnode.com/@Juanzen)

[Aug 2, 2021](https://hashnode.com/posts/add-dark-mode-to-your-react-application-with-tailwindcss/61041520805a765b08876fc8/comment/610774b033a2a43971a2f556#reply-6107d104fd46bb4ece8c29b0)

Thank you, Shantun. I'm glad you enjoyed it 🙂
