-
Notifications
You must be signed in to change notification settings - Fork 68
Open
Labels
enhancementNew feature or requestNew feature or request
Description
This project has started pretty organically and now that #137 is getting close, it may be time to think about refactoring the code for clarity for contributors.
Broadly, there are two ways that this project can be used:
- As a stand-alone map rendering/demo.
- As a dependency of another map, a style that another application would want to use as a basemap or to render its data.
The stand-alone map/demo case is currently what we've been focused on, but the inclusion of the style as a dependency of other projects shouldn't be too far off.
Here are some steps that might get us there, though I'm probably missing a few and these should be discussed:
- Move
package.json
to the root of the repository if there isn't a good reason to bury it instyle/
. - Move
index.html
out of thestyle/
directory either to the root or to ademo/
orsite/
subdirectory. - Move the config and maplibre calls out of
americana.js
into anindex.js
ordemo.js
that goes with the demo'sindex.html
. This should leaveamericana.js
exporting a style object with all layers that is as complete as possible and which can be passed added in the demo or other map renderings after having the source tweaked to add the access key or change the source url. - Any dependencies for the demo should be included when running
npm i --include=dev
. Any dependencies that are needed only when used as a library should be included by default. - If the style needs to distribute built artifacts for consumption by downstream users, these should be added as addition tasks and packaged as releases.
Thoughts? What did I miss?
I think this is blocked by #137, but I could be wrong.
clementmas and michaelblyonsclementmas
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request