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 setting default route transition (page/layout) properties globally

See original GitHub issue

currently it’s only possible to set transition props on a per route basis with definePageMeta, or via something like this:

export default defineNuxtConfig({
  modules: [
    // ...
    function (options, nuxt) {
      nuxt.hook('pages:extend', (pages) => {
        for (const page of pages) {
          page.meta = {
            layoutTransition: false,
            pageTransition: false,
          }
        }
      })
    }
  ],
})

It would be better to support configuring this so it can easily be disabled or set on a project-wide base

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:3
  • Comments:8 (6 by maintainers)

github_iconTop GitHub Comments

3reactions
Atinuxcommented, Jul 6, 2022

What about:

import { defineNuxtConfig } from 'nuxt'

export default defineNuxtConfig({
  app: {
    layoutTransition: false,
    pageTransition: false
  }
})
1reaction
Atinuxcommented, Aug 23, 2022

Read about the progress in #5859, as soon as it is merged, you will be able to use it by switching to the edge channel.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Set default transition for go_router in Flutter - Stack Overflow
However, I want to set the default PageTransition for all pages. How do I set the default page transition with/for go_router in Flutter?...
Read more >
Transitions - Nuxt
Nuxt uses the transition component to let you create amazing ... The layout transition is used to set the default properties of the...
Read more >
Route transition animations - Angular
Implement a router transition animation that slides in the new view to the right and slides out the old view when navigating between...
Read more >
Animating Route Transitions with React Router
Configure Routes and Browser Router. With the pages set to be rendered, let's define their routes and what paths they should be rendered...
Read more >
Vue Router Page Transitions with Fade, Slide and Zoom Effects
In the code snippet above, you can see that we give the transition the name fade , and we set the mode property...
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