Quantcast
Channel: Active questions tagged svelte - Stack Overflow
Browsing all 1539 articles
Browse latest View live

SvelteKit: [vite] [postcss] error - Unknown Word

I'm currently developing a desktop application using Tauri, SvelteKit, & Tailwind. When I run a dev build of my application I frequently get the following error: [vite] Internal server error:...

View Article


How to import a Svelte component into a JS file

I'm working on a project using both of native JS and Svelte.And I worked on a Svelte component and I want to know how can I import this later into my JS file.*index.js*// js code here alert('here is my...

View Article


SvelteKit: Run function at route change (for access token, without doing it...

I just started with SvelteKit and I have a question regarding functions, that should run on every route change. I did not find much, helpful information about it.Just to run it at the layout files...

View Article

How to use svelte directives on components using svelte runes?

I have this svelte component that is currently using the use: directive from svelte runes:<script> import {route} from "@mateothegreat/svelte5-router"; let {children, className, ...rest} =...

View Article

Svelte 5 Error "Not implemented type annotation EmptyStatement" when using...

my coworker has got a really strange bug with svelte 5 where doing this works fine{#snippet test()}<span>Hello world</span>{/snippet}<div> {@render test()}</div>Adding...

View Article


Error Hosting Svelte SPA from ASP.NET Core App in IIS: Uncaught (in promise)...

I am getting an error when trying to run a Svelte 5 (with SvelteKit) application as a SPA hosted by an ASP.NET Core application in IIS.I am building the app using astatic adapter with a fallback file...

View Article

Can not find module while mocking a library in JEST?

I am using a module name as prop-typeshttps://www.npmjs.com/package/prop-types.In .svelte file using: import PropTypes from "prop-types"; const { checkPropTypes, bool, func, string } = PropTypes;I am...

View Article

How to get details of clicked row or cell in gridjs-svelte using the rowClick...

In the gridjs documentation, it suggests the following code should work to collect details on a clicked row or cell:const grid = new Grid({ columns: ['Name', 'Email', 'Phone Number'], sort: true,...

View Article


Why is this object not updating?

Reproduction: https://svelte.dev/playground/4424d522f50847f0b872a094b7b2198b?version=5.18.0I cannot understand why this error:[svelte] binding_property_non_reactive`bind:value={content.one}`...

View Article


Imported Svelte State not updating

I am running into a error with reactive state in Svelte 5 with SvelteKit.I've written a simple helper for syncing a state with remote data.// $lib/remoteProxy.svelte.jsexport const remoteProxy = (val,...

View Article

SvelteKit loads favicon every page request

Does anybody have the same problem with SvelteKit? Why does it load the favicon on every page request? see attachment

View Article

Image may be NSFW.
Clik here to view.

svelte $state considered undefined by eslint?

My code runs fine which makes me think it comes from the linter. Also, when I close the file in VScode it's green, but when I open it it goes red. in my shared.svelte.js file:Here are the dependencies...

View Article

TypeError [ERR_IMPORT_ATTRIBUTE_MISSING]: Module "package.json" needs an...

There are no errors when launching the application, and the application functions normally, but if you log in to the server logs, a permanent error appears.Error in the logs:2024-03-23_04:59:51.32690...

View Article


How to Enable Safari Autofill for SMS OTP in Svelte Using BitsUI’s PinInput...

I’m working on implementing an SMS OTP login in Svelte, similar to Auth0’s login flow. I’m using the PinInput component from BitsUI to handle the OTP input fields. My goal is to enable autofill for the...

View Article

Svelte without Shadow-Dom not possible?

How to build a Svele-Component without shadow-DOM?There are a lot of discussions on GitHub1748 (2018)4073 (PR / 2019)2516 (2019 / with Comment from Rich Harris, but he also had no clear answer)Until...

View Article


Supabase Auth exchangeCodeForSession returns "invalid request: both auth code...

Architecture:This is Cross-Platform web-based (SEO focused) project, that was built in CSR due to bad performance using SSR w/ Capacitor framework.Client: Svelte + Vite + CapacitorDue to use of vanilla...

View Article

How to animate card fade in and fade out inplace in svelte

How would I create the following animation in svelte?what I am trying to do:I have a two div elements. When I click on a button, firs div element fades out while the second div element fades in. Both...

View Article


How can I implement login and logout in my svelte 5 project?

I'm developing the frontend side of a school website. The users don't have to register, they only can login or logout.I've already developed the login page but the data is not updating properly, The...

View Article

Dynamically imported SVG icons not working

I am using svelte 5 / sveltekit 2I have a simple example where I get data from an API that looks like this const itemsFromAPI = [ { id: 1, symbols: ['btc', 'eth'] }, { id: 2, symbols: ['xrp', 'xmr'] }...

View Article

Image may be NSFW.
Clik here to view.

Certain parts of extension only update when refreshing the extension

I hope this is the right place to ask, if it's not, please tell me where I should post it.I'm making a pomodoro timer browser extension using WXT and Svelte.js with Typescript. My extension works quite...

View Article
Browsing all 1539 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>