StatCan / dataviz-components

Data visualizations components made with D3.js
Other
6 stars 3 forks source link

Charts do not render in any of the demo applications under source #1

Open DamourYouKnow opened 5 years ago

DamourYouKnow commented 5 years ago

Opening either the line-en.html or line-fr.html demo files using any web browser results in the following error:

utils.js:31 Uncaught TypeError: Cannot read property 'en' of undefined at utils.js:31

This behaviour is reproducible with any of the other dataviz components.

Perhaps I am missing a step somewhere? Please let me know if there is anything else I should be doing to run the demo files.

LaurentGoderre commented 5 years ago

Are you running the file via a local web server or opening the file locally?

LaurentGoderre commented 5 years ago

It looks to me like the translation files are not loading

DamourYouKnow commented 5 years ago

I'm trying to run the files locally right now. I'll try accessing them through a Node.js web server when I get the chance to do so.

LaurentGoderre commented 5 years ago

It's possible to make it work locally but you have to disable a bunch of security settings to allow it. When browsing files, every file that isn't in the current directory is treated as a cross origin request and blocked for security reasons