Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reactivity not working on ios safari #602

Closed
cocoliliace opened this issue Apr 9, 2024 · 6 comments
Closed

Reactivity not working on ios safari #602

cocoliliace opened this issue Apr 9, 2024 · 6 comments

Comments

@cocoliliace
Copy link

cocoliliace commented Apr 9, 2024

Describe the bug

Variables do not update and no reactivity-related feature works, on ios safari with software version 12.5.7.

By not working I mean nothing changes when the variables are supposed to update.

Reproduction

https://git.sr.ht/~liliace/reactive-example

This is a skeleton project from running pnpm create svelte@latest and copying the code from https://learn.svelte.dev/tutorial/reactive-assignments into src/routes/+page.svelte.

I believe it is an issue with the reactivty part and not the on:click (or at least not just on:click) because using a setInterval to update the variable also works on firefox but not on safari. My other projects using other reactivity code like input binding also have the same issue.

Logs

Unfortunately there are no error logs on mobile safari

System Info

Unfortunately cannot run this on ipod. Below is the system info hosting the local dev server:

  System:
    OS: Linux 6.8 Alpine Linux
    CPU: (12) x64 13th Gen Intel(R) Core(TM) i7-1355U
    Memory: 10.69 GB / 15.31 GB
    Container: Yes
    Shell: 5.2.26 - /bin/bash
  Binaries:
    Node: 21.7.2 - /usr/bin/node
    npm: 10.5.1 - /usr/bin/npm
    pnpm: 8.15.6 - /usr/bin/pnpm
  npmPackages:
    svelte: ^4.2.7 => 4.2.12

It is a gen 6 ipod, with software version 12.5.7, running safari.

Severity

blocking all usage of svelte

@cocoliliace
Copy link
Author

cocoliliace commented Apr 9, 2024

This may be difficult to reproduce and work on due to the hardware requirement. Although I probably can't contribute much on the code because of my lack of understanding of the internal code and browser differences, I can help test different changes and report the behaviour if anyone has some guesses or starting directions.

@zhihengGet
Copy link

maybe u can record a video

@Conduitry Conduitry transferred this issue from sveltejs/svelte Apr 9, 2024
@cocoliliace
Copy link
Author

I see that the issue is transferred from sveltejs/svelte to sveltejs/learn.svelte.dev. I'd like to clarify that although I linked the tutorial as the reproduction, this issue exists on local builds too, with any code that uses reactivity.

@cocoliliace
Copy link
Author

maybe u can record a video

Below is a screen recording of the behaviour on ipod. The button flashing is when I clicked on the button:

E3DF33D2-2B1B-4E6C-BA2E-B17F7AD0D7F1.MOV

The code for the local host is the same as the tutorial example:

<script>
	let count = 0;

	function increment() {
		count += 1;
	}
</script>

<button on:click={increment}>
	Clicked {count}
	{count === 1 ? 'time' : 'times'}
</button>

@cocoliliace
Copy link
Author

Should this issue be transferred back to sveltejs/svelte? I may have caused some confusion by linking the tutorial example as the reproduction code. The issue I mean to report is about the framework itself, causing all svelte projects with reactivity to behave unexpectedly.

I have updated the reproduction link to a custom repository to make it more clear.

@cocoliliace
Copy link
Author

Closing this and re-opning at sveltejs/svelte#11869.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants