Open Rushijoshi3798 opened 1 month ago
Hi Team,
I am getting below error every time when I run the "npm run dev" command.
` Unexpected Server Error
ReferenceError: y is not defined `
After getting this error I am not able to proceed with our application (Even Print 'Hello world' is not working on the _index.jsx file ).
But npm run build & then npm run start works just fine as if nothing had happened.
npm run build
npm run start
Details:
Node Version - v20.11.1 Npm Version - 10.2.4
Package.Json -
{ "name": "easemyactivity", "private": true, "sideEffects": false, "type": "module", "scripts": { "build": "remix vite:build", "dev": "remix vite:dev", "lint": "eslint --ignore-path .gitignore --cache --cache-location ./node_modules/.cache/eslint .", "start": "remix-serve ./build/server/index.js", "typecheck": "tsc" }, "dependencies": { "@remix-run/node": "^2.9.1", "@remix-run/react": "^2.9.1", "@remix-run/serve": "^2.9.1", "isbot": "^4.1.0", "react": "^18.2.0", "react-dom": "^18.2.0" }, "devDependencies": { "@remix-run/dev": "^2.9.1", "@types/react": "^18.2.20", "@types/react-dom": "^18.2.7", "@typescript-eslint/eslint-plugin": "^6.7.4", "@typescript-eslint/parser": "^6.7.4", "autoprefixer": "^10.4.19", "eslint": "^8.38.0", "eslint-import-resolver-typescript": "^3.6.1", "eslint-plugin-import": "^2.28.1", "eslint-plugin-jsx-a11y": "^6.7.1", "eslint-plugin-react": "^7.33.2", "eslint-plugin-react-hooks": "^4.6.0", "postcss": "^8.4.38", "tailwindcss": "^3.4.3", "typescript": "^5.1.6", "vite": "^5.1.0", "vite-tsconfig-paths": "^4.2.1" }, "engines": { "node": ">=18.0.0" } }
System: OS: Windows 11 10.0.22631 CPU: (12) x64 AMD Ryzen 5 5500U with Radeon Graphics Memory: 591.44 MB / 5.86 GB Binaries: Node: 20.11.1 - C:\Program Files\nodejs\node.EXE npm: 10.2.4 - C:\Program Files\nodejs\npm.CMD Browsers: Edge: Chromium (124.0.2478.51) Internet Explorer: 11.0.22621.1 npmPackages: @remix-run/dev: ^2.9.1 => 2.9.1 @remix-run/node: ^2.9.1 => 2.9.1 @remix-run/react: ^2.9.1 => 2.9.1 @remix-run/serve: ^2.9.1 => 2.9.1 vite: ^5.1.0 => 5.2.11
npm
npm run dev should run properly.
npm run dev
npm run dev is giving
Unexpected Server Error ReferenceError: y is not defined
There's not much information here that we can use to triage. Can you provide a minimal reproduction of the issue?
Reproduction
Hi Team,
I am getting below error every time when I run the "npm run dev" command.
` Unexpected Server Error
ReferenceError: y is not defined `
After getting this error I am not able to proceed with our application (Even Print 'Hello world' is not working on the _index.jsx file ).
But
npm run build
& thennpm run start
works just fine as if nothing had happened.Details:
Node Version - v20.11.1 Npm Version - 10.2.4
Package.Json -
{ "name": "easemyactivity", "private": true, "sideEffects": false, "type": "module", "scripts": { "build": "remix vite:build", "dev": "remix vite:dev", "lint": "eslint --ignore-path .gitignore --cache --cache-location ./node_modules/.cache/eslint .", "start": "remix-serve ./build/server/index.js", "typecheck": "tsc" }, "dependencies": { "@remix-run/node": "^2.9.1", "@remix-run/react": "^2.9.1", "@remix-run/serve": "^2.9.1", "isbot": "^4.1.0", "react": "^18.2.0", "react-dom": "^18.2.0" }, "devDependencies": { "@remix-run/dev": "^2.9.1", "@types/react": "^18.2.20", "@types/react-dom": "^18.2.7", "@typescript-eslint/eslint-plugin": "^6.7.4", "@typescript-eslint/parser": "^6.7.4", "autoprefixer": "^10.4.19", "eslint": "^8.38.0", "eslint-import-resolver-typescript": "^3.6.1", "eslint-plugin-import": "^2.28.1", "eslint-plugin-jsx-a11y": "^6.7.1", "eslint-plugin-react": "^7.33.2", "eslint-plugin-react-hooks": "^4.6.0", "postcss": "^8.4.38", "tailwindcss": "^3.4.3", "typescript": "^5.1.6", "vite": "^5.1.0", "vite-tsconfig-paths": "^4.2.1" }, "engines": { "node": ">=18.0.0" } }
System Info
Used Package Manager
npm
Expected Behavior
npm run dev
should run properly.Actual Behavior
npm run dev
is givingUnexpected Server Error ReferenceError: y is not defined