Comments (1)
d3-fetch’s behavior is whatever the standard Fetch behavior is (in the current browser); D3 is not a compatibility layer. If the native Fetch API doesn’t support local file URLs, then neither does d3-fetch.
If you want to fetch local files, you could:
-
Encourage browser vendors to enable this feature, such as by voicing your support for it by filing or staring an issue (e.g., Chrome’s issue).
-
Use a different native API, such as XMLHttpRequest (perhaps with d3-request).
-
Write a new library, perhaps as a wrapper around d3-fetch (or Fetch), that somehow works around the issue.
You could also consider running your own local web server so that you don’t need access to the local file system, which may be the path of least resistance. Also note that browsers allow you to read local files using <input type=file>
; see Reading Local Files for example.
from d3-fetch.
Related Issues (20)
- Access denied under Basic Authentication HOT 3
- ReferenceError: fetch is not defined HOT 4
- json method not working on newest version.. HOT 5
- Documentation gap for POST between d3-request and d3-fetch HOT 1
- JSON fetching discrepancy between v4 and v5 HOT 5
- Localhost slow data loading HOT 1
- Async await with d3 fetch functions? HOT 1
- d3.text() decode UTF-16 HOT 4
- Response's body lost when error is thrown HOT 1
- d3.append returns undefined when appending result from xml() HOT 3
- How to handle fetch errors? HOT 1
- How to initialise graph object from Javascript object?
- Is there going to be an on.("progress", ...) equivalent for d3 v5? HOT 1
- Fetching large files always gives up at 50MiB HOT 1
- Fix incompatibility with strict/safe CSP HOT 1
- Including d3-fetch.v1.js causes d3.svg to be undefined in nv.d3.js HOT 8
- d3.json interprets HTTP 204 as errors HOT 3
- mention workarounds for all those environments where networks don't allow JS-loading CSV files HOT 2
- d3.json doesn't recognize my function as a RequestInit HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from d3-fetch.