6eDesign / svelte-calendar

A lightweight datepicker with neat animations and a unique UX.
https://6edesign.github.io/svelte-calendar/
MIT License
543 stars 90 forks source link

Failed to resolve force included dependency: just-throttle #149

Open babakfp opened 2 years ago

babakfp commented 2 years ago

Hi So, Github just recommended this repo and it was interesting I take a look and... I decided to create a replication repo for this issue https://github.com/6eDesign/svelte-calendar/issues/141 and I got this error:

On the browser

500
Line must be greater than or equal to 1, got -1
TypeError: Line must be greater than or equal to 1, got -1
    at BasicSourceMapConsumer.SourceMapConsumer_findMapping [as _findMapping] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58887:13)
    at BasicSourceMapConsumer.SourceMapConsumer_originalPositionFor [as originalPositionFor] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58956:22)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59897:34
    at String.replace (<anonymous>)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59885:21
    at Array.map (<anonymous>)
    at ssrRewriteStacktrace (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59884:10)
    at instantiateModule (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60108:28)

On the console

warn - No utilities were generated there is likely a problem with the `content` key in the tailwind config. For more information see the documentation: https://tailwindcss.com/docs/content-configuration
11:04:58 AM [vite] Error when evaluating SSR module /node_modules/.pnpm/just-throttle@2.3.1/node_modules/just-throttle/index.js?v=3a966951:
ReferenceError: module is not defined
    at /node_modules/.pnpm/just-throttle@2.3.1/node_modules/just-throttle/index.js?v=3a966951:1:1
    at instantiateModule (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60105:15)
11:04:58 AM [vite] Error when evaluating SSR module /node_modules/.pnpm/svelte-calendar@3.1.6/node_modules/svelte-calendar/components/calendar/DayPicker.svelte:
TypeError: Line must be greater than or equal to 1, got -1
    at BasicSourceMapConsumer.SourceMapConsumer_findMapping [as _findMapping] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58887:13)
    at BasicSourceMapConsumer.SourceMapConsumer_originalPositionFor [as originalPositionFor] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58956:22)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59897:34
    at String.replace (<anonymous>)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59885:21
    at Array.map (<anonymous>)
    at ssrRewriteStacktrace (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59884:10)
    at instantiateModule (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60108:28)
11:04:58 AM [vite] Error when evaluating SSR module /node_modules/.pnpm/svelte-calendar@3.1.6/node_modules/svelte-calendar/components/calendar/Calendar.svelte:
TypeError: Line must be greater than or equal to 1, got -1
    at BasicSourceMapConsumer.SourceMapConsumer_findMapping [as _findMapping] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58887:13)
    at BasicSourceMapConsumer.SourceMapConsumer_originalPositionFor [as originalPositionFor] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58956:22)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59897:34
    at String.replace (<anonymous>)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59885:21
    at Array.map (<anonymous>)
    at ssrRewriteStacktrace (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59884:10)
    at instantiateModule (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60108:28)
11:04:58 AM [vite] Error when evaluating SSR module /node_modules/.pnpm/svelte-calendar@3.1.6/node_modules/svelte-calendar/components/Datepicker.svelte:
TypeError: Line must be greater than or equal to 1, got -1
    at BasicSourceMapConsumer.SourceMapConsumer_findMapping [as _findMapping] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58887:13)
    at BasicSourceMapConsumer.SourceMapConsumer_originalPositionFor [as originalPositionFor] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58956:22)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59897:34
    at String.replace (<anonymous>)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59885:21
    at Array.map (<anonymous>)
    at ssrRewriteStacktrace (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59884:10)
    at instantiateModule (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60108:28)
11:04:58 AM [vite] Error when evaluating SSR module /node_modules/.pnpm/svelte-calendar@3.1.6/node_modules/svelte-calendar/index.js:
TypeError: Line must be greater than or equal to 1, got -1
    at BasicSourceMapConsumer.SourceMapConsumer_findMapping [as _findMapping] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58887:13)
    at BasicSourceMapConsumer.SourceMapConsumer_originalPositionFor [as originalPositionFor] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58956:22)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59897:34
    at String.replace (<anonymous>)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59885:21
    at Array.map (<anonymous>)
    at ssrRewriteStacktrace (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59884:10)
    at instantiateModule (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60108:28)
11:04:58 AM [vite] Error when evaluating SSR module /src/routes/index.svelte:
TypeError: Line must be greater than or equal to 1, got -1
    at BasicSourceMapConsumer.SourceMapConsumer_findMapping [as _findMapping] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58887:13)
    at BasicSourceMapConsumer.SourceMapConsumer_originalPositionFor [as originalPositionFor] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58956:22)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59897:34
    at String.replace (<anonymous>)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59885:21
    at Array.map (<anonymous>)
    at ssrRewriteStacktrace (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59884:10)
    at instantiateModule (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60108:28)
Line must be greater than or equal to 1, got -1
TypeError: Line must be greater than or equal to 1, got -1
    at BasicSourceMapConsumer.SourceMapConsumer_findMapping [as _findMapping] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58887:13)
    at BasicSourceMapConsumer.SourceMapConsumer_originalPositionFor [as originalPositionFor] (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:58956:22)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59897:34
    at String.replace (<anonymous>)
    at C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59885:21
    at Array.map (<anonymous>)
    at ssrRewriteStacktrace (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:59884:10)
    at instantiateModule (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60108:28)

I refresh the page and it works now: Screenshot 2022-01-23 110622 But it was still giving me the same error in the console.

Then I find out this Usage within svelte-kit project. So, now nothing works😂

Failed to resolve force included dependency: just-throttle
    at optimizeDeps (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:56544:27)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)    at async runOptimize (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60549:48)
    at async Server.httpServer.listen (C:\Users\babak\Desktop\New folder (2)\node_modules\.pnpm\vite@2.7.13\node_modules\vite\dist\node\chunks\dep-f5552faa.js:60565:21)
 ELIFECYCLE  Command failed with exit code 1.

I couldn't find anything about Failed to resolve force included dependency on Google.

That's all.