sveltekit-quirrel-esm

A crontab sveltekit app that works with quirrel.

Now there is a clash between luxon and es6 settings :

When launching "production" version with node:

npm run prod

Then loading the home page is generating a 500 error with:

Listening on 0.0.0.0:3000
file:///home/dev/src/sveltekit-quirrel-esm/build/server/chunks/_server.ts-f169324c.js:11
import require$$0$4 from 'luxon';
       ^^^^^^^^^^^^
SyntaxError: The requested module 'luxon' does not provide an export named 'default'
    at ModuleJob._instantiate (node:internal/modules/esm/module_job:131:21)
    at async ModuleJob.run (node:internal/modules/esm/module_job:213:5)
    at async ModuleLoader.import (node:internal/modules/esm/loader:316:24)
    at async Promise.all (index 1)
    at async render_page (file:///home/dev/src/sveltekit-quirrel-esm/build/server/index.js:3161:19)
    at async resolve (file:///home/dev/src/sveltekit-quirrel-esm/build/server/index.js:3886:24)
    at async respond (file:///home/dev/src/sveltekit-quirrel-esm/build/server/index.js:3772:22)
    at async Array.ssr (file:///home/dev/src/sveltekit-quirrel-esm/build/handler.js:1221:3)

For more information see this issue

Creating the project

Created with:

npm create svelte@latest sveltekit-quirrel-esm

Then updated to create a link with quirrel

Quirrel setting

You must launch quirrel, with docker it is:

docker run -ti -p 9181:9181 -e PASSPHRASES=quirrel_passphrase ghcr.io/quirrel-dev/quirrel:1.13.4

Once you've ran quirrel, you have to generate a token:

npm run initQuirrel

Building

To create a production version of your app:

npm ci
npm run dev

To build a production version:

npm run build

You can preview the production build with npm run preview.

Top categories

svelte logo

Need a Svelte website built?

Hire a professional Svelte developer today.
Loading Svelte Themes