-
Notifications
You must be signed in to change notification settings - Fork 27.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove traces of glamor #1286
Remove traces of glamor #1286
Conversation
As talked about with @rauchg. Glamor takes up around 60KB of the bundle (pre-gzip). Since styled-jsx is the way to go now and we support adding glamor by the user we should remove it as dependency cause it is bundled even when not used. Added rehydration to the example, since we did that in our code. There is only one thing I'm not sure about and want to discuss: what should we do with next/css. Right now I added a throw for when it is imported. I'm not sure if we should do that / some other way to notify the user it has been removed. The reasoning behind the throw is that when we would do a console.warn the user would see 'css.default.<X>' not found because we don't have the glamor dependency anymore.
I thought we were gonna release 2.0 with the deprecation then soon after 3.0 without glamor? :thinking_face: |
@albinekb yeah but we've done enough betas to let people migrate at this point, and we didn't realize that the glamor bundle was just as big as the next.js bundle before :( |
LGTM @rauchg, yeah sounds right. I think most users are on beta now 😄 |
…amor # Conflicts: # yarn.lock
Ready for merge. |
Great work @timneutkens as always. |
@arunoda ❤️ ❤️ ❤️ |
As talked about with @rauchg. Glamor takes up around 60KB of the bundle (pre-gzip). Since styled-jsx is the way to go now and we support adding glamor by the user we should remove it as dependency cause it is bundled even when not used.
Added rehydration to the example, since we did that in our code.
There is only one thing I'm not sure about and want to discuss:
what should we do with
next/css
. Right now I added a throw for when it is imported. I'm not sure if we should do that / some other way to notify the user it has been removed. The reasoning behind the throw is that when we would do a console.warn the user would seecss.default.<X>
not found because we don't have the glamor dependency anymore.Fixes #989
Fixes #1108