Comments (7)
No worries I'll try to have a look tonight/tomorrow and let you know
from alpine-turbo-drive-adapter.
@zepfietje
I was able to replicate and find the bug (705d496 😄 ).
Before I tag a new release, could you try https://cdn.jsdelivr.net/gh/alpinejs/alpine-turbolinks-adapter@bug/sibling-x-for-disappearing/dist/alpine-turbolinks-adapter.min.js and confirm it resolves your bug please? Thanks.
from alpine-turbo-drive-adapter.
Thanks for the bug report.Just to clarify. Are we saying that something like
<div x-data="{foo: ['one', 'two'], bar: ['red', 'blue']}">
<template x-for="item1 in foo">
<p x-text="item1"></p>
</template>
<template x-for="item2 in bar">
<p x-text="item2"></p>
</template>
</div>
will result in the second loop being removed when navigating back to the page?
<div x-data="{foo: ['one', 'two'], bar: ['red', 'blue']}">
<template x-for="item1 in foo">
<p x-text="item1"></p>
</template>
</div>
from alpine-turbo-drive-adapter.
@SimoTod, thanks for your clear snippets. That's exactly what seems to happen when using the adapter.
I haven't put together a minimal reproducible example though.
from alpine-turbo-drive-adapter.
@SimoTod awesome! I can confirm it resolves the bug in my project.
from alpine-turbo-drive-adapter.
Thanks for confirming. I tagged a new version. It's a patch release so if you use the generic CDN link (0.1.x) you won't need to update the link. Since served by a CDN (I don't have control over it), it could take up to 24h to update.
from alpine-turbo-drive-adapter.
@SimoTod, thanks again for the quick fix!
from alpine-turbo-drive-adapter.
Related Issues (20)
- Missing readme
- x-for elements disappearing after Livewire rerender HOT 11
- v0.2.0 - x-for loop items disappear HOT 3
- Use Alpine.clone to avoid existing component being reset when navigating using the history. HOT 7
- IE 11 support HOT 4
- Turbo Drive compatibility HOT 12
- Issue with data-turbolinks-permanent combined with x-cloak HOT 3
- fail when render status: :unprocessable_entity HOT 32
- Figure out if the plugin is testable somehow HOT 9
- JS file always runs after the turbo:load event, causing x-data to throw a ReferenceError on first navigation HOT 6
- Turbo stream - not initialising HOT 5
- after fired turbo:render x-data not exists HOT 12
- Currently Breaks with Alpine.js & Livewire HOT 14
- Add github action to publish the library on npm when a new version is tagged. HOT 1
- Alpine v3 compatability HOT 36
- How can I keep the cdn link updated HOT 5
- Necessary if caching disabled? HOT 1
- Add npm instructions HOT 3
- Components hidden by default, such as mobile navigation menus, get cached and cause flickering when navigating between pages. HOT 19
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from alpine-turbo-drive-adapter.