Failed to import geotiff in vue project
See original GitHub issueI have import GeoTIFF from 'geotiff'
in a vue file, and run npm run dev
with the following error:
error in ./node_modules/geotiff/src/geotiff.js
Module parse failed: Unexpected token (283:35)
You may need an appropriate loader to handle this file type.
| }
|
| return usedImage.readRasters({ ...options, window: wnd });
| }
| }
@ ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./src/components/layers/Basemap.vue 9:0-30
@ ./src/components/layers/Basemap.vue
@ ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./src/App.vue
@ ./src/App.vue
@ ./src/main.js
@ multi (webpack)-dev-server/client?http://localhost:8080 webpack/hot/dev-server ./src/main.js
Issue Analytics
- State:
- Created 3 years ago
- Comments:9 (3 by maintainers)
Top Results From Across the Web
Unable to import an API module into a nested component (Vue)
I've been struggling with a very odd bug(?) with regards to importing an API module into a nested component in a Vue app....
Read more >JSDoc: Home - geotiff.js
geotiff.js works with both require , import and the global variable GeoTIFF : const GeoTIFF = require('geotiff'); const { fromUrl, fromUrls, fromArrayBuffer ...
Read more >70 questions with answers in GEOTIFF | Science topic
You can import GEOTIFF using "image" file type in PETREL (the importing option is start with "bitmap") and assign coordinate on the setting...
Read more >jest unexpected token 'export' uuid - You.com | The AI Search ...
Is anyone else having this error in an Angular project due to a 3rd party ... jest.config.ts import type {Config} from "@jest/types"; const...
Read more >Failed to import geotiff in vue project - error - Insight
How to handle the openlayers error: Failed to import geotiff in vue project · You may need an appropriate loader to handle this...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I’m trying to install stable version of Opelayers 6.13.0 and I’m having the same issue as this depends on geotiff. It currently installs geotiff@2.0.4 and still gives the same error: ERROR in ./node_modules/geotiff/dist-module/geotiff.js Module parse failed: Unexpected token (276:35) You may need an appropriate loader to handle this file type. | } | | return usedImage.readRasters({ …options, window: wnd }); | } | }
Same problem here.