-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Im using a basic vite + svelte + ts setup and just importing AniList fails with this error:
3:29:52 PM [vite] (client) Pre-transform error: Failed to resolve entry for package "@spkrbox/anilist". The package may have incorrect main/module/exports specified in its package.json.
Plugin: vite:import-analysis
File: /home/gapls/Progmramming/JavaScript/AnilistSMK/src/App.svelte:2:37
5 |
6 | import * as $ from 'svelte/internal/client';
7 | import { AniList, MediaType } from '@spkrbox/anilist';
| ^
8 |
9 | var root = $.add_locations($.from_html(`<main><div></div> <h1>Vite + Svelte</h1> <p>Check out <a href="https://github.com/sveltejs/kit#readme" target="_blank" rel="noreferrer">SvelteKit</a>, the official Svelte app framework powered by Vite!</p> <p class="read-the-docs">Click on the Vite and Svelte logos to learn more</p></main>`), App[$.FILENAME], [[5, 0, [[6, 2], [7, 2], [9, 2, [[10, 14]]], [17, 2]]]]);
3:29:52 PM [vite] Internal server error: Failed to resolve entry for package "@spkrbox/anilist". The package may have incorrect main/module/exports specified in its package.json.
Plugin: vite:import-analysis
File: /home/gapls/Progmramming/JavaScript/AnilistSMK/src/App.svelte:2:37
5 |
6 | import * as $ from 'svelte/internal/client';
7 | import { AniList, MediaType } from '@spkrbox/anilist';
| ^
8 |
9 | var root = $.add_locations($.from_html(`<main><div></div> <h1>Vite + Svelte</h1> <p>Check out <a href="https://github.com/sveltejs/kit#readme" target="_blank" rel="noreferrer">SvelteKit</a>, the official Svelte app framework powered by Vite!</p> <p class="read-the-docs">Click on the Vite and Svelte logos to learn more</p></main>`), App[$.FILENAME], [[5, 0, [[6, 2], [7, 2], [9, 2, [[10, 14]]], [17, 2]]]]);
at packageEntryFailure (file:///home/gapls/Progmramming/JavaScript/AnilistSMK/node_modules/vite/dist/node/chunks/dep-BHkUv4Z8.js:12175:32)
at resolvePackageEntry (file:///home/gapls/Progmramming/JavaScript/AnilistSMK/node_modules/vite/dist/node/chunks/dep-BHkUv4Z8.js:12172:2)
at tryNodeResolve (file:///home/gapls/Progmramming/JavaScript/AnilistSMK/node_modules/vite/dist/node/chunks/dep-BHkUv4Z8.js:12073:17)
at ResolveIdContext.resolveId (file:///home/gapls/Progmramming/JavaScript/AnilistSMK/node_modules/vite/dist/node/chunks/dep-BHkUv4Z8.js:11912:15)
at async EnvironmentPluginContainer.resolveId (file:///home/gapls/Progmramming/JavaScript/AnilistSMK/node_modules/vite/dist/node/chunks/dep-BHkUv4Z8.js:31208:19)
at async TransformPluginContext.resolve (file:///home/gapls/Progmramming/JavaScript/AnilistSMK/node_modules/vite/dist/node/chunks/dep-BHkUv4Z8.js:31390:13)
at async normalizeUrl (file:///home/gapls/Progmramming/JavaScript/AnilistSMK/node_modules/vite/dist/node/chunks/dep-BHkUv4Z8.js:29991:22)
at async file:///home/gapls/Progmramming/JavaScript/AnilistSMK/node_modules/vite/dist/node/chunks/dep-BHkUv4Z8.js:30057:32
at async Promise.all (index 3)
at async TransformPluginContext.transform (file:///home/gapls/Progmramming/JavaScript/AnilistSMK/node_modules/vite/dist/node/chunks/dep-BHkUv4Z8.js:30025:4)
This is in the package.json under dependencies:
"@spkrbox/anilist": "^1.0.4"
Metadata
Metadata
Assignees
Labels
No labels