"full:dev": "concurrently \"strapi develop\" \"cd frontend && npm run dev\"",
By running npm run full:dev --jsx I’m getting error:
[1] > next dev
[1] Error: > Couldn't find any `pages` or `app` directory. Please create one under the project root
[1] at findPagesDir (/Users/abc/javascript/ecomm/HeadlessComm/node_modules/next/dist/lib/find-pages-dir.js:42:15)
ERROR in ./frontend/src/app/layout.tsx:18:5
[0] TS17004: Cannot use JSX unless the '--jsx' flag is provided.
package.json file:
{
"name": "headlessecomm",
"private": true,
"version": "0.1.0",
"description": "A Strapi and next.js application",
"scripts": {
"develop": "strapi develop",
"dev": "next dev",
"full:dev": "concurrently \"strapi develop\" \"cd frontend && npm run dev\"",
"backend:start": "strapi start",
"backend:build": "strapi build",
"strapi": "strapi",
"deploy": "strapi deploy",
"frontend:build": "next build",
"frontend:start": "next start",
"lint": "next lint"
},
"devDependencies": {
"@types/node": "^20",
"@types/react": "^18",
"@types/react-dom": "^18",
"eslint": "^8",
"eslint-config-next": "14.2.4",
"postcss": "^8",
"tailwindcss": "^3.4.1",
"typescript": "^5"
},
"dependencies": {
"@strapi/plugin-cloud": "4.25.2",
"@strapi/plugin-graphql": "4.25.2",
"@strapi/plugin-i18n": "4.25.2",
"@strapi/plugin-users-permissions": "4.25.2",
"@strapi/strapi": "4.25.2",
"pg": "8.8.0",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"react-router-dom": "5.3.4",
"styled-components": "5.3.3",
"concurrently": "^8.2.2",
"next": "14.2.4"
},
"compilerOptions": {
"jsx": "react"
},
"author": {
"name": "abc-3"
},
"strapi": {
"uuid": "b3a229fa-a2e6-449e-85a1-823c6f9b2b38"
},
"engines": {
"node": ">=18.0.0 <=20.x.x",
"npm": ">=6.0.0"
},
"license": "MIT"
}
This topic has been created from a Discord post (1260463398785912875) to give it more visibility.
It will be on Read-Only mode here.
Join the conversation on Discord