Last active
October 5, 2018 19:08
-
-
Save haldarmahesh/dadce6156b5527ed0578dc25e04a8fdf to your computer and use it in GitHub Desktop.
medium-react-context-demo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import lightLogo from './../assets/medium_light.png'; | |
import darkLogo from './../assets/medium_dark.png'; | |
export const themeConfig = { | |
light: { | |
headerBg: '#F7B30C', | |
fontColor: 'black', | |
bodybg: 'white', | |
logo: lightLogo | |
}, | |
dark: { | |
headerBg: '#3c3c3c', | |
fontColor: 'white', | |
bodybg: 'black', | |
logo: darkLogo | |
} | |
}; | |
const ThemeContext = React.createContext(themeConfig.light); | |
export default ThemeContext; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment