Comments (7)
It won't help here. The API of GA cannot be dead code eliminated as it goes through the untyped ga
function
from eleventy-high-performance-blog.
It's a 1:1 copy of https://www.google-analytics.com/analytics.js
In theory the size could be reduced, but in practice this would be quite difficult and also users of the template might use a bigger feature set of GA and actually need that JS.
from eleventy-high-performance-blog.
FWIW I landed e46b53c yesterday to make it easy to turn this off completely, or rather make it off by default.
from eleventy-high-performance-blog.
But IMO Lighthouse audit is hinting that part of the code in cached.js is redundant i.e. DCE is not happening completely; theoretically rollup should be ideally removing any extraneous code from this file.
from eleventy-high-performance-blog.
Thank you. I was striving to get that elusive 100 % in the LightHouse perf score๐
from eleventy-high-performance-blog.
One thing to consider would be to delay loading the GA file a bit. But that would only cheat the Lighthouse test and not actually improve UX
from eleventy-high-performance-blog.
Its all for reader's experience; Lighthouse are just indicators for that. Thank you for your time on this, I will close the issue.
from eleventy-high-performance-blog.
Related Issues (20)
- Issue with javascript and some considerations about this amazing starter
- how can i add more navigations besides "about" HOT 3
- Feature: Internationalization HOT 2
- CSP Headers Injection to non-standard _headers; htaccess instead. HOT 1
- Web Vitals max
- Image blurring works weird with transparent PNGs HOT 6
- GA issue #46 should not be hard-coded HOT 2
- Mocha as a `dependency` HOT 3
- Twitter Web Intents HOT 1
- Tags do not function correctly HOT 4
- ENOENT: no such file or directory, image plugin issue? HOT 3
- ffmpeg struggles converting gifs with odd dimensions
- Original site seems to fix Nav styles
- Largest Contentful Paint image was lazily loaded HOT 3
- AllowDomainlist CORS in ga.js depends on deployment platform HOT 2
- "clean" no such command as rm HOT 1
- Add support for Google Analytics 4 HOT 5
- No more CSP meta headers HOT 1
- Does this project work with PostCSS files? HOT 1
- Trying to change behaviour of img-dim setSrcset function HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from eleventy-high-performance-blog.