Skip to content
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

script.js should get minified #6547

Closed
albertlast opened this issue Feb 28, 2021 · 3 comments
Closed

script.js should get minified #6547

albertlast opened this issue Feb 28, 2021 · 3 comments
Labels
Not enough details Issue doesn't provide enough details/documentation for it to be reproduced.

Comments

@albertlast
Copy link
Collaborator

albertlast commented Feb 28, 2021

Description

While checking some network traffic stuff,
i notice that we transfer the complet scripts.js file without minified it.
When i send this throw a minifier the file get from ~60kb to 40kb,
so should this be done somewhere, maybe in build tools?

The values are without gzip.

In best case we also generate some map files for minified version so that development is possible on this files,
when wanted.
https://stackoverflow.com/questions/21719562/how-to-use-javascript-source-maps-map-files

@Oldiesmann
Copy link
Contributor

Doesn't it get minified with the rest of the JS stuff when you enable that option in the admin center?

@jdarwood007
Copy link
Member

Only if you have minified enabled in the settings and your themes scripts/css folder is writable by the process running php.

@sbulen
Copy link
Contributor

sbulen commented Mar 4, 2021

I have confirmed script.js is getting successfully minimized in 2.1. Not sure there's an error here.

@sbulen sbulen added the Not enough details Issue doesn't provide enough details/documentation for it to be reproduced. label Mar 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Not enough details Issue doesn't provide enough details/documentation for it to be reproduced.
Projects
None yet
Development

No branches or pull requests

4 participants