Skip to main content
Filter by
Sorted by
Tagged with
0 votes
1 answer
22 views

How to mock $env/static/public with vitest?

I'm using an env variable MY_VAR that I use from $env/static/public import { MY_VAR } from '$env/static/public'; export const myVar = MY_VAR === 'true'; I'd like to mock it in some tests, to support ...
Valentin Vignal's user avatar
0 votes
1 answer
21 views

`onmouseenter` is not triggered

I have this piece of code: <script lang="ts"> let visible = $state(false); </script> <div role="button" tabindex="0" onmouseenter={() =>...
Valentin Vignal's user avatar
-1 votes
1 answer
34 views

passing children's layout.ts data to parent's layout.svelte

So I have been working on the implementation of breadcrumbs feature in my sveltekit webapp. The idea is, the breadcrumb will be rendering at the most top layout.svelte. And then the proceeding ...
Muhammad Najid's user avatar
0 votes
0 answers
42 views

Returning an array from server-side to client-side in Svelte 5

I am using Svelte5. When I send an array from +page.server.js to +page.svelte it always works server-side and the array is sent as expected. However when +page.svelte is running on the client side ...
k4mars's user avatar
  • 11
1 vote
1 answer
37 views

How to invalidate an arbitrary cache?

I have a simple +page.ts showing the data string and providing the "Update" button: <script lang="ts"> import { invalidateAll } from '$app/navigation'; const { data }...
Seva Golovanov's user avatar
0 votes
1 answer
40 views

Building Svelte Kit application for deployment on Azure webapps

I have built a Svelte Kit application that utilises a couple of Microsoft Graph endpoints to pull from our internal news SharePoint sites. It works perfectly fine in dev and when I use the preview ...
Charlie's user avatar
0 votes
1 answer
44 views

How to delete the user after logout in Sveltekit using runes?

I am trying to get auth working in my sveltekit 2.20.7 / svelte 5.27.0 application I have an express backend that runs on port 8000 and uses express-session with connect-redis and passport to provide ...
PirateApp's user avatar
  • 6,278
0 votes
0 answers
40 views

why does svelte-kit dev return "Invalid command: dev" error?

I am trying to run a svelte project with the following command > npm run dev but I am getting this error ERROR Invalid command: dev Run `$ svelte-kit --help` for more info. svelte-kit is ...
Prat13k's user avatar
  • 31
1 vote
2 answers
83 views

How to check when window becomes available?

I am new to SvelteKit and I am not familiar with SSR. I have recently learned that window is only defined after the client-side has been loaded, which can be determined with the onMount hook. But here'...
Donald Zhu's user avatar
0 votes
1 answer
24 views

Using IntersectionObserver breaks SvelteKit prerender, which results in 404 on direct urls

I have a static site that I deploy to GitHub pages (GHP). I first build it locally and then deploy the output to GHP. Which is why all the data is in JSON files that are updated and deployed when eg. ...
Juha Untinen's user avatar
  • 1,887
0 votes
0 answers
43 views

Login is possible but my supabase user / session is not "authenticated", GoTrueClient getSession() session from storage null

The stack: SvelteKit / Supabase (with docker) To authenticate the users i followed the supabase tutorial (so my code strictly follows that). It works as i receive the user's data (profile, session...)....
alegarn's user avatar
0 votes
1 answer
26 views

Google App Engine - endpoint "GET /_ah/start HTTP/1.1" 500

When updating my application's configuration from scaling to manual, I repeatedly encountered this error in the console: Error: Cannot find module '/workspace/index.js', followed by multiple errors of ...
gru's user avatar
  • 41
0 votes
1 answer
50 views

SvelteKit container on Azure App Service page rewrite issue /project/1 being ameneded to /project/undefined/project/1?

I have a SvelteKit with Svelte 5 application which I am deploying to the Azure App Service inside of a Docker container. I have routes with a parameter set up like: route/ - project - [id] ...
sean_robbins's user avatar
0 votes
1 answer
48 views

MatterJS Ball Not Affected by Gravity in version 0.20.0

I'm trying to integrate a game, built with matter-js, into my existing SvelteKit webapp but am getting stumped as to why gravity is not affecting the circle body I'm adding. The following is the ...
ClosingArc's user avatar
0 votes
1 answer
18 views

SvelteKit Duplicate Routes in Layout Groups

Is it possible to have the same route be on different layout groups in SvelteKit. I want to have two different layout groups "/(private)/(app)" and "/(public)/(landing)" that ...
Rey Christian Eustaquio's user avatar

15 30 50 per page
1
2 3 4 5
201