Patrick

Results 61 comments of Patrick

I was trying to use the `@ionic/core` components in svelte (and maybe build Svelte components around them), but I am not able to configure rollup to import the components. I've...

I don't think `button` elements (and button-like `input` elements (with type="button|submit|reset|...?")) need a key handler, it works as expected with only a click handler. I think all those `input` types...

How about something like that? https://svelte.dev/repl/237823ed53614c60902db0745dff0d6e?version=3.49.0

> ```svelte > > export let user: {name: string, age: number};// ← comes from the main component through "bind:user" > > $: nameChanged(user.name); > function nameChanged(newName) { > reload(); //...

> I really like [...] & `forward:use:action`. Should definitely make it in. What should `forward:use:action` do? `action` is a function that the component author specifies. It gets executed, and then?...

I think something that you can use like this would be good: ```html import { onMount } from 'svelte'; import { onNavigate } from '@sapper/app'; onMount(() => onNavigate(() => !isFormUnsaved...

As of now, svelte/kit does not have a solution for this. For anyone who needs this for the current sapper version, you can use my [sapper-navigation-enhancer](https://github.com/PatrickG/sapper-navigation-enhancer) package. Im planning to...

Probably because of [this line](https://github.com/sveltejs/sapper/blob/5757a85d195f9ceb2e329caa5e3e38abd5a1123d/runtime/src/app/router/index.ts#L216) A timeout should fix it. ```js function focus(node) { setTimeout(() => { node.focus(); console.log('node: ', node) console.log('activeElement: ', window.document.activeElement) console.log('equality: ', node === document.activeElement) console.log('window:...

Why not simply check in the preload function if you need to fetch the data?

Actually, the preload function runs on the server and the client. You could do the following ```html import { store } from '../stores/products'; import { get } from 'svelte/store'; export...