Skip to content
Tushar Banik edited this page Mar 7, 2024 · 18 revisions

Web browser on local index.html file is blank?

The animint() function creates a local directory with HTML/JavaScript files to render the data viz, but these days most web browsers have a default setting which blocks execution of JavaScript from local files. The easiest way to solve this issue is by enabling local JavaScript execution in your web browser. For example in Firefox:

  • Open up a new tab. Type or paste about:config in the address bar and press Enter.
  • A button appears asking if you accept the risk to change advanced settings. Click that you accept the risk.
  • Type origin in the search box, which will filter the list for words containing this word.
  • Double click the privacy.file_unique_origin or security.fileuri.strict_origin_policy preference (depending on your firefox version) to switch the value from true to false

Or in Chrome follow this SO answer: https://stackoverflow.com/questions/20748630/load-local-javascript-file-in-chrome-for-testing/25107674

If it still doesn't work out,one workaround is to use Firefox for local rendering.

  1. Download and install Firefox: Firefox Download
  2. Follow the steps mentioned above for enabling local JavaScript execution in Firefox.

Alternatively, instead of using animint(viz) which saves/renders on your local computer, you can try publishing your animint on the web using one of the other sharing methods such as GitHub pages.

Clone this wiki locally