Hello developers i have been facing this problem i am using babel with nodemon @babel/cl @babel/core @babel/node @babel/preset-env in e commerce website it was working perfectly fine but after upgraded my node js its not working but working with yarn start not with npm start
Error: Requires Babel "^7.0.0-0", but was loaded with "6.26.3". If you are sure you have a compatible version of @babel/core, it is likely that something in your build process is loading the wrong version. Inspect the stack trace of this error to look for the first entry that doesn't mention "@babel/core" or "babel-core" to see what is calling Babel. (While processing preset: "C:\Users\japolinar\Documents\orion-github\pt-orion-rh\node_modules@babel\preset-env\lib\index.js")
debugg console
Debugger attached.
(node:11132) Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.
(Use `node --trace-warnings ...` to show where the warning was created)
Waiting for the debugger to disconnect...
c:\Users\im\Desktop\E commerc webs to pract\jsamazona\backend\server.js:4
import express from 'express';
^^^^^^
SyntaxError: Cannot use import statement outside a module
at wrapSafe (internal/modules/cjs/loader.js:988:16)
at Module._compile (internal/modules/cjs/loader.js:1036:27)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1101:10)
at Module.load (internal/modules/cjs/loader.js:937:32)
at Function.Module._load (internal/modules/cjs/loader.js:778:12)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:76:12)
at internal/main/run_main_module.js:17:47