geotiffjs / geotiff.js

geotiff.js is a small library to parse TIFF files for visualization or analysis. It is written in pure JavaScript, and is usable in both the browser and node.js applications.
https://geotiffjs.github.io/
MIT License
878 stars 183 forks source link

Make sources and package ES module compliant #269

Closed ahocevar closed 2 years ago

ahocevar commented 2 years ago

This pull request takes the minimal changes from @tschaub's vite branch (see https://github.com/geotiffjs/geotiff.js/pull/242#issuecomment-936776217) to make geotiff.js work with vite. The only changes are that all local imports now have a .js extension, and package.json got a "type": "module" entry and an "exports" map.

This is a breaking change for those who had to work around issues with the geotiff package by importing modules from geotiff/src/geotiff.js instead of just geotiff.