-
-
Notifications
You must be signed in to change notification settings - Fork 565
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
chore: update nuxt to v3.9.3 and vue 3.4.15 #2543
Conversation
Run & review this pull request in StackBlitz Codeflow. |
✅ Deploy Preview for elk-docs canceled.
|
❌ Deploy Preview for elk-zone failed.
|
# Conflicts: # composables/tiptap/shikiji-parser.ts # package.json # pnpm-lock.yaml
addEventListener: (type: string, listener: (evt: PageLifecycleEvent) => void) => void | ||
get state(): PageLifecycleState | ||
get pageWasDiscarded(): boolean | ||
addUnsavedChanges: (id: symbol | any) => void |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not Symbol?
nuxt.config.ts
Outdated
@@ -84,6 +89,17 @@ export default defineNuxtConfig({ | |||
build: { | |||
target: 'esnext', | |||
}, | |||
optimizeDeps: { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change looks like a problem on the compile-time schedule, and probably a regression from Nuxt with the ability to create dependency between modules..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any change here is more likely a change in Vite (as we upgraded from Vite 4 -> Vite 5 in v3.9).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I included the list for testing (testing with current main and this PR on my local), I need to remove all entries, we only need focus trap for client
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it is a good idea to include most of these in the config. We're lazy loading a lot of dependencies and they aren't discovered by the scanner. Some will end up triggering a full-reload on cold start. We may merge a new strategy in Vite 5.1 that we can adopt and this will be even more important then (we will start getting warnings to add the deps to the config). See:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
has anyone in the team tried running dev in a clean clone (main branch with Nuxt 3.8)? there are almost 10 page refresh even when scrolling on timeline
@patak-dev I'm going to activate Vite 5 { server: { fs: cachedChecks: true } }
;)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@userquin see nuxt/nuxt#24196 (comment), there were issues in Nuxt 3.8 preventing the optimized deps cache to be used (so every startup was a cold start). This should be fixed in 3.9 (I imagine also in newer patches for 3.8?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm going to include also the new floating-vue v5.0.0 :fingers_crossed:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@patak-dev I don't see any improvement activating cachedChecks: true
on my laptop (with or without optimized deps, just a few ms, in both cases removing the .cache
folder):
# without cachedChecks: true
ℹ Vite server warmed up in 8133ms 15:02:18
ℹ Vite client warmed up in 12612ms 15:02:19
✔ Nitro built in 5417 ms
# with cachedChecks: true
ℹ Vite server warmed up in 8190ms 15:03:23
ℹ Vite client warmed up in 12484ms 15:03:24
✔ Nitro built in 5196 ms
# Conflicts: # composables/content-parse.ts
# Conflicts: # package.json # pnpm-lock.yaml
# Conflicts: # package.json # scripts/generate-pwa-icons.ts
Closing, as #2610 has now been merged. |
This PR also updates some nuxt modules to latest version, changed also configuration for new i18n module.
Right now it is not working, I guess some problem with vue-macros, the paginator watcher not triggering
loadNext
, adding immediate works but the browser hangs after a few seconds or when scrolling.We also need to review nuxt security module, added a new patch (when this PR ready we can remove old patch).