Skip to content

Commit

Permalink
feat(loaders): avoid warning during ssr
Browse files Browse the repository at this point in the history
  • Loading branch information
posva committed Sep 3, 2024
1 parent 2fd131d commit 99d7b0b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/data-loaders/navigation-guard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export function setupLoaderGuard({
}

// explicit dev to avoid warnings in tests
if (process.env.NODE_ENV === 'development') {
if (process.env.NODE_ENV === 'development' && !isSSR) {
console.warn(
'[vue-router]: Data Loader is experimental and subject to breaking changes in the future.'
)
Expand Down

0 comments on commit 99d7b0b

Please sign in to comment.