Search code examples
javascripthtmllocal-storagenavigator

Why is navigator.storage undefined in latest Chrome?


I'm trying to use navigator.storage on http://0.0.0.0:5000 while developing locally, but navigator.storage is undefined.

When/why can navigator.storage be undefined?

I'm in Chrome 77.


Solution

  • As per @Ry-'s comment, using http://localhost:5000 or http://127.0.0.1:5000 instead of http://0.0.0.0:5000 does the trick.

    For some reason the browser decides to make navigator.storage unavailable when visiting a URL on http://0.0.0.0.