Comments (4)
This can only be completed after #169
from nexus2.
copying @berosen 's notes here:
So from what I can tell, the problem is with the data. To begin with, the converted shapefiles -->geojsons are in EPSG 3857 (default coordinate system for leaflet). 3857 is a coordinate system that represents its coordinates in meters, if you take a look at the points that we are loading onto the map the, coordinates are in degrees. Obviously does not match 3857.
Leaflet might do some re-projecting on the fly to match the points and the basemap then take the crs from there. I'll have to look into how it handles projecting data. So most likely the reason it isn't appearing properly is that the 2 data sets are on different coordinate systems.
Here is what I can as the "action items"... I feel everything i said above was rabble rabble.
-Tell me source of the data for the array passed to MapView
-We determine the coordinate system of that data and have new geojsons match or vice versa.
I believe this should fix the problem, just a little bit of data cleaning. Seems easy but might end up being a pain.
Pre-note:
In the meantime I think it would be useful to unit-test your geojson loading process in a basic leaflet environment, you can just use that skeleton html that I sent over a couple weeks ago I think, that way we can see that A) the crs is actually the problem B) your loading implementation works.
Note:
I ran the geojson I was originally using to displace place names through a linter and it said it wasn't a valid geojson. Unsure of how everything was functioning before but non the less lets start with the easier/more obvious situation I outlined above haha
from nexus2.
Proposed solution: create a separate map component specifically for fieldtrip view to allow for different map data types to render.
from nexus2.
https://stackoverflow.com/questions/44155385/rendering-geojson-with-react-leaflet
from nexus2.
Related Issues (20)
- Drag and drop broken on Firefox HOT 1
- Unable to type to change timeline's year boundaries
- convert shape files to polyline
- production build can't find book epub file :(
- Fieldtrip View + filter feature
- Highlight similar nodes feature HOT 1
- Pin tabs
- URL Routing
- Preserving selected topic index
- Set-up docker container HOT 5
- Set-up automated testing in Nightwatch.js
- Write docker set-up tutorial on the readme
- Encoding /n character HOT 1
- Font +/- Functionality in StoryView HOT 1
- Reorder StoryView Tabs
- Redesign the help view
- Non-core informants should not have a Full Biography button
- Styling for StoryView
- clean up sessionStorage HOT 1
- Search bar suggestions positioning
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 nexus2.