question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Allow playing transitions on initial render

See original GitHub issue

Describe the problem

In Svelte, you can play transitions on initial render by setting intro: true in the component constructor. There doesn’t seem to be a way to do this in SvelteKit.

Describe the proposed solution

Add a setting in svelte.config.js that will set intro: true in the component constructor. This would only apply during the initial render. After client-side navigation, transitions should play automatically as components are mounted.

Alternatives considered

No response

Importance

nice to have

Additional Information

No response

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:18
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
talwatcommented, Nov 8, 2022

It might also be a good idea to be able to enable this functionality per-component or per-page. I really need this feature in my own project and it would be very nice to have.

0reactions
3mdistalcommented, Sep 13, 2022

It’s the same problem, yes. This library provides a hacky workaround you can use for now: https://fractils.fractal-hq.com/#OnMount

Read more comments on GitHub >

github_iconTop Results From Across the Web

Applying React.js CSS Transitions on initial render
In this post I'm going to explore a quick solution to applying React.js CSS transitions to components when they are first rendered to...
Read more >
vue.js - VueJS: Enable transition only after FIRST load
Right now the value is initially rendered as 0 and then after loading it changes to 16, so the transition will play.
Read more >
Applying transitions in Premiere Pro
Follow this step-by-step guide to select, apply, and customize transitions in Premiere Pro.
Read more >
Using No-Op Transitions To Prevent Animation During The ...
Ben Nadel demonstrates how to use a no-op (No Operation) transition in Angular 5.2.6's Browser Animations module to block animations during ...
Read more >
Avoiding flash of unwanted animation on first render in React
By adding this transition in my initial CSS, the menu will be transformed to the right side of the screen but with a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found