While using Grafana 4, I noticed in the Chrome Dev tools that the JS dependency files being served to the browser are non-minified JS files.
I was trying to see if I can improve the performance of the load time and was hoping that setting the app_mode configuration to “production” would serve the minified JS dependencies but it seems it does not. angular,js takes a little over a second to load. I did find that the minified version in the public/vendor/angular directory.
I was wondering if there was a way to get Grafana to serve the minified JS files?
Most core js files are minified and bundled in on big js file. If you see files loading unminified one at a time you must e running a custom development build
@torkel Thanks for responding. You were right in pointing out that we were running a custom development environment and building this from source.
I fixed the issue by running
grunt release
which provides the necessary files into /public_gen
I did notice that running
go run build.go test
produces a result that does not serve minified JS files. Which just meant I ran the tests first (as should be the case) and then ran the grunt command.
Thank you for your help with this! And I apologize for not replying with my findings sooner.