File tree 1 file changed +4
-5
lines changed
packages/@sanity/cli/src/actions/init-project
1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -337,11 +337,10 @@ export default async function initSanity(
337
337
const packageJson = readPackageJson ( `${ outputPath } /package.json` )
338
338
const reactVersion = packageJson . dependencies ?. react
339
339
const isUsingReact19 = semver . coerce ( reactVersion ) ?. major === 19
340
- if (
341
- detectedFramework ?. slug === 'nextjs' &&
342
- detectedFramework ?. detectedVersion ?. startsWith ( '15' ) &&
343
- isUsingReact19
344
- ) {
340
+ const isUsingNextJs15 =
341
+ detectedFramework ?. slug === 'nextjs' && detectedFramework ?. detectedVersion ?. startsWith ( '15' )
342
+
343
+ if ( isUsingNextJs15 && isUsingReact19 ) {
345
344
warn ( '╭────────────────────────────────────────────────────────────╮' )
346
345
warn ( '│ │' )
347
346
warn ( '│ It looks like you are using Next.js 15 and React 19 │' )
You can’t perform that action at this time.
0 commit comments