svelte Questions
2
I am trying to setup a bare minimum configuration using Svelte + PouchDB and running into the above error in the browser. Please see below the steps to reproduce the issue.
Steps to reproduce:
Cre...
12
Solved
I have written a validation class and want to include it in my VueJS 3 project. Unfortunately I get the following error: SyntaxError: ambiguous indirect export: default
This is my code:
// ..classe...
Fungiform asked 22/9, 2022 at 11:21
3
Solved
The title pretty much says it all. I am very new to web development.
I created a Svelte app using npx degit sveltejs/template .... Now I run it locally using npm run dev or npm start.
To my unde...
4
Solved
I am experimenting with Svelte and following the official tutorial. At https://svelte.dev/tutorial/reactive-assignments, I am instructed to use this line of code:
<button on:click={handleClick}...
Froggy asked 15/11, 2019 at 21:5
3
I've created a SvelteKit webapp that works great on my desktop in my local environment. I launch the browser/webserver with:
npm run dev -- --open
Now I've just deployed to Vercel. Everything work...
Obi asked 16/6, 2021 at 0:55
7
I'm using the following combination of technologies:
SvelteKit (1.5.0, using TypeScript), with Vite (4.0.0) as the build tool that comes with SvelteKit)
Svelte's adapter-static (2.0.1) for publish...
Haulm asked 1/3, 2023 at 8:45
5
Using the latest SvelteKit (1.0.0-next.401) I have a problem importing components from lib using the $lib syntax. I get an error and a red squiggly line (even though the import and web app works fi...
Tallula asked 1/8, 2022 at 8:23
4
Solved
I'm currently trying to redirect the user to a new page when they clicked on a href link.
The problem is that the url does change per se, but only when I manually hit "reload", the page a...
6
Solved
My sveltekit app has a form which sends a POST request to server. The app is working fine on dev server but when I build and run the app it fails to send the form data via POST request. It shows th...
6
Solved
I came across this strange error in Svelte; every time I ran npm run dev, this vite error would appear:
[vite] Internal server error: Failed to load PostCSS config (searchPath: /Users/Documents/Per...
Theory asked 27/7, 2022 at 10:41
3
Solved
I'm building an embed that needs access to a sveltkit endpoint from any origin.
If I was using express I would simply use the cors middleware.
I'm curious if there is a way to enable CORS on sveltk...
Mammoth asked 2/8, 2022 at 22:58
5
Solved
Please excuse me if this is a naive question.
I would like to parse markdown inside a Svelte component, something like
<script>
--- import some markdownLibrary ---
export let text; // text...
3
Solved
I have a page with content rendered from a SvelteKit store. If the store is invalid, a user needs do be redirected to the homepage. Unfortunately, I can't find a way to redirect a user even without...
Hamrick asked 14/12, 2022 at 23:17
4
I'm halfway through the Svelte docs and I have a hard time understanding the tick() lifecycle. Is there an alternative to it in React?
For example, what it actually does in this example from the ...
Ghiselin asked 18/4, 2020 at 19:51
2
Solved
I have a question about svelte, if svelte is not adapting Virtual DOM or Shadow DOM mechanism, how is it generating high performance applications, because svelte is just a compiler, which generates...
Ardolino asked 23/3, 2023 at 12:53
5
Solved
I get error message this when build.
Cannot access url.searchParams on a page with prerendering enabled
How to load and use get parameter?
svelte.config.js
import adapter from '@sveltejs/adapter-...
4
Solved
I am trying to serve a PDF file that my SvelteKit app generates and allow a user to download it from an endpoint.
My project structure looks like this:
---------------------
/src/routes/downloads
-...
3
Solved
I am checking the logs of the SvelteKit SSR server using adapter-node.
I have customised the server.js to use Express instead of Polka, though not sure if this matters.
There are apparent errors wh...
Oscillogram asked 16/1, 2023 at 17:55
2
Solved
I want this to be fully client side rendering.. So, I don't want to refresh the page just to redo the promise..
Here's the code that I made..
{#await myFetchMethod("/api/v1/me")}
<Loading /&g...
Garton asked 17/7, 2019 at 4:7
3
I'm wondering if there is a way to avoid exceptions to freeze entire Svelte app?
I'm currently using Svelte v3.12.0 and it looks like if there is an uncaught exception, the entire front end app ju...
Desolate asked 11/11, 2019 at 5:52
4
Solved
I have a route structure /items/[category]. When the user is browsing /items/category1 and then tries to go to a another page in the same route (eg. /items/category2) the page data usually updates ...
2
Could someone help me with this jsonfig.json file for a svelte project? It's saying that the importsNotUsedAsValues option should be replaced with verbatimModuleSyntax.
{
"compilerOptions&quo...
Allx asked 9/4, 2023 at 9:45
2
When you create empty Svelte component (eg. ComponentName.svelte) like this:
<script>
export let segment;
</script>
<style>
</style>
<svelte:head>
<title>Lo...
Own asked 26/10, 2019 at 14:20
5
Solved
The approach of my graphic designer for formatting our Svelte application is having a systematic set of classes in LESS, importing the appropriate LESS file in the component or page, and then apply...
3
Solved
I'm new to svelte and I am trying to use an installed node module in my dependancies called momentum-slider. In the script tags of my svelte component I have:
import MomentumSlider from "../.....
© 2022 - 2024 — McMap. All rights reserved.