-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tidy up the package.json #35
Conversation
I can't remember why main was originally set to "dist/stac-layer.min.js". I just know I've similarly set main to a build when there was some issue with a dependency using a more recent JS syntax like Could you also set jsdelivr to "dist/stac-layer.min.js" (which you may already know is what ObservableHQ uses for their default AMD loading)? This isn't required for merging because it wasn't there originally, but it would be a nice to have. I think you mentioned this in another thread, but the bulk of the build is probably coming from https://www.npmjs.com/package/proj4js-definitions. Just wanted to mention this here in case anyone else is interested and reading this. I intentionally specified all the files in "files: [...]" instead of using |
Yeah, I think we put the .min file in there as we had issues with vue-cli/webpack bundling the new syntax of the Nullish coalescing operator etc. I'm not sure whether this has been solved yet. We should check this so that we can ensure nothing breaks, because gaining the mentioned benefits would be great. |
Actually, I think we should not care whether downstream there's an issue. If there's one, we need to fix it downstream. It's really a bad idea to fix something here that in reality should be fixed somewhere else. Let's merge this and then we'll figure things out in STAC Browser once released. This should be released as 0.11.0 and not as 0.10.2 ideally. Edit: Did some tests and this seems to work after upgrading some dependencies in STAC Browser. |
This PR fixes up some of the pointers in the package.json.
Currently the
stac-layer.min.js
is 1.3MB. I'm pretty sure it's bundling all the dependencies such as leaflet.js etc in a way that means they might not being tree-shaken.This PR should mostly resolve the issues in this repo, but I'm going to open some similar PR's upstream in georaster packages to try and fix some similar issues (eg GeoTIFF/georaster#65).