Expected behavior:
Using function rules I want to be able to create media queries which depend on props and get updated on props change.
Describe the bug:
Media queries dont get updated on props change.
Reproduction:https://codesandbox.io/s/react-jss-playground-forked-ekg58?file=/index.js
Clicking the Toggle Button changes the breakpoint for the media query. console.log shows, that the string gets generated, but the change is not reflected in the html output. Try changing the width of the output html view. Before clicking the toggle button, breakpoint width is 720px, where bakcground color changes red/blue. After clicking toggle button, it should be 480px.
Versions ():
react-jss: 10.5.1
Browser: was able to reproduce in current Chrome and Firefox browsers
Expected behavior: Using function rules I want to be able to create media queries which depend on props and get updated on props change.
Describe the bug: Media queries dont get updated on props change.
Reproduction: https://codesandbox.io/s/react-jss-playground-forked-ekg58?file=/index.js Clicking the Toggle Button changes the breakpoint for the media query. console.log shows, that the string gets generated, but the change is not reflected in the html output. Try changing the width of the output html view. Before clicking the toggle button, breakpoint width is 720px, where bakcground color changes red/blue. After clicking toggle button, it should be 480px.
Versions ():