Bundle visualizer not displayed

Hi,

I upgraded to 1.5 but can’t get bundle visualizer working. During build there is minification taking place, I can see .stats.json file filled with size data in the bundle. But I see nothing when I load http://localhost:3000 (neither grey overlay which was mentioned in similar topic). I can also see css classes of bundle visualizer in the browsers inspector.

I tried to reinstall Meteor from scratch but did not help too.

I run meteor as follows

meteor --production --settings settings-dev.json

Related packages versions:

bundle-visualizer              1.0.3  Meteor bundle analysis and visualization.
standard-minifier-js           2.1.0  Standard javascript minifiers used with Meteor apps by default.

Server output (there is no error neither on the client nor server side):

Warning: The --production flag should only be used to simulate production bundling for testing purposes. Use meteor build to create a bundle for production deployment. See: https://guide.meteor.com/deployment.html
[[[[[ ~/proj1/app ]]]]]          

=> Started proxy.                             
=> Started your app.

=> App running at: http://localhost:3000/
W20170614-13:43:43.830(2)? (STDERR) => The "bundle-visualizer" package is currently enabled. Visit your application in a web browser to view the client bundle analysis and 'meteor remove' the package before building/deploying the final bundle.

Any ideas appreciated

Thank you, Jiri

1 Like

Interesting! I’ll probably have you file a bug with the Issue Tracker, but it’d be nice if we could figure out a way to reproduce it first.

Can you “Inspect” the page in your browser Developer Tools and find the div tags with the meteorBundleVisualizer class? Toward the end of the DOM (just before the </body> tag), there should be a:

<div class="meteorBundleVisualizer meteorBundleVisualizerRootContainer"></div>

…and a…

<div class="meteorBundleVisualizer meteorBundleVisualizerMask"></div>

I can’t see such divs in the inspector.

Tried to put breakpoints at the file bundle-visualizer/client.js (in dev mode). Browser dev tools debugger catches Meteor.startup() call but did not catch import(’./sunburst.js’) call inside later, it seems document.body.appendChild(mask) and following call of Meteor method from the main function from the same file is never called.

Does it happen on a brand new project created with meteor create test-app? If not, maybe try using an incognito/private window without extensions to rule out the possibility of some extension interfering? (Can’t imagine what, though!)

I missed one error in another Meteor.startup() routine called before, which prevented following Meteor.statup() calls from bundle visualizer. Fix it did the trick. Thank you.

1 Like