Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: [BABEL]: Cannot find module '@babel/plugin-proposal-private-property-in-object' #15

Open
zalatmza opened this issue Oct 25, 2021 · 1 comment

Comments

@zalatmza
Copy link

复现路径:

前置工作:

node -v 
// v14.17.3

npm i -g  @alicloud/xconsole

xconsole init

当我运行npm start后出现报错

> [email protected] start /Users/weichen/develop/alibaba/xconsole/hello
> xconsole start

 INFO  正在检查不必要的包依赖...
 INFO  非常好,未检查到不必要的依赖包的引入! 点赞!
BreezrPluginStyledComponentsIsolation  The plugin will trying to use the package's name as isolation id of styled-components. This behavior usually occurred on dev mode. And if you were received this warning on publish mode then you should to set `options.styledComponentStyleSheetId` implicitly.
Happy[jsx]: Version: 5.0.1. Threads: 3
(node:3626) DeprecationWarning: Tapable.plugin is deprecated. Use new API on `.hooks` instead
(Use `node --trace-deprecation ...` to show where the warning was created)
ℹ 「wds」: Project is running at http://localhost:3333/
ℹ 「wds」: webpack output is served from undefined
ℹ 「wds」: Content not from webpack is served from /Users/weichen/develop/alibaba/xconsole/hello
ℹ 「wds」: 404s will fallback to /index.html
Happy[jsx]: All set; signaling webpack to proceed.
Starting type checking service...
Using 1 worker with 4089MB memory limit

✖ Webpack
  Compiled with some errors in 1.84s

监听到 pages 下文件变化,重新生成 .xconsole 内容
监听到 pages 下文件变化,重新生成 .xconsole 内容
Type checking in progress...
✖ 「wdm」: 
ERROR in ./.xconsole/index.js
Module build failed (from ../node_modules/happypack/loader.js):
Error: [BABEL]: Cannot find module '@babel/plugin-proposal-private-property-in-object'
Require stack:
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-preset-breezr/lib/createPlugins.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-preset-breezr/lib/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@babel/core/lib/config/files/module-types.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@babel/core/lib/config/files/configuration.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@babel/core/lib/config/files/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@babel/core/lib/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-loader/lib/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/happypack/lib/applyLoaders.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/happypack/lib/HappyWorker.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/happypack/lib/HappyWorkerChannel.js (While processing: /Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-preset-breezr/lib/index.js)
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
    at Function.Module._load (internal/modules/cjs/loader.js:746:27)
    at Module.require (internal/modules/cjs/loader.js:974:19)
    at require (internal/modules/cjs/helpers.js:92:18)
    at Object.<anonymous> (/Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-preset-breezr/lib/createPlugins.js:185:1)
    at Module._compile (internal/modules/cjs/loader.js:1085:14)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
    at Module.load (internal/modules/cjs/loader.js:950:32)
    at Function.Module._load (internal/modules/cjs/loader.js:790:14)
    at Module.require (internal/modules/cjs/loader.js:974:19)
 @ multi ../node_modules/error-overlay-webpack-plugin/lib/entry-basic.js ../node_modules/error-overlay-webpack-plugin/lib/entry-devserver.js? ../node_modules/webpack-dev-server/client?http://localhost:3333 ../node_modules/webpack/hot/dev-server.js ./.xconsole/index.js index[4]
ℹ 「wdm」: Failed to compile.
ℹ 「wdm」: Compiling...

✖ Webpack
  Compiled with some errors in 784.78ms

Type checking in progress...
✖ 「wdm」: 
ERROR in ./.xconsole/index.js
Module build failed (from ../node_modules/happypack/loader.js):
Error: [BABEL]: Cannot find module '@babel/plugin-proposal-private-property-in-object'
Require stack:
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-preset-breezr/lib/createPlugins.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-preset-breezr/lib/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@babel/core/lib/config/files/module-types.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@babel/core/lib/config/files/configuration.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@babel/core/lib/config/files/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@babel/core/lib/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-loader/lib/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/happypack/lib/applyLoaders.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/happypack/lib/HappyWorker.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/happypack/lib/HappyForegroundThreadPool.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/happypack/lib/HappyPlugin.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@alicloud/console-toolkit-plugin-react/lib/webpack/rules/jsx/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@alicloud/console-toolkit-plugin-react/lib/webpack/rules/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@alicloud/console-toolkit-plugin-react/lib/webpack/common.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@alicloud/console-toolkit-plugin-react/lib/webpack/dev.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@alicloud/console-toolkit-plugin-react/lib/development.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@alicloud/console-toolkit-plugin-react/lib/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@alicloud/console-toolkit-core/lib/Service.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@alicloud/console-toolkit-core/lib/index.js
- /Users/weichen/develop/alibaba/xconsole/hello/node_modules/@alicloud/xconsole/bin/xconsole.js (While processing: /Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-preset-breezr/lib/index.js)
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
    at Function.Module._load (internal/modules/cjs/loader.js:746:27)
    at Module.require (internal/modules/cjs/loader.js:974:19)
    at require (internal/modules/cjs/helpers.js:92:18)
    at Object.<anonymous> (/Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-preset-breezr/lib/createPlugins.js:185:1)
    at Module._compile (internal/modules/cjs/loader.js:1085:14)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
    at Module.load (internal/modules/cjs/loader.js:950:32)
    at Function.Module._load (internal/modules/cjs/loader.js:790:14)
    at Module.require (internal/modules/cjs/loader.js:974:19)
    at require (internal/modules/cjs/helpers.js:92:18)
    at Object.<anonymous> (/Users/weichen/develop/alibaba/xconsole/hello/node_modules/babel-preset-breezr/lib/index.js:8:39)
    at Module._compile (internal/modules/cjs/loader.js:1085:14)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
    at Module.load (internal/modules/cjs/loader.js:950:32)
    at Function.Module._load (internal/modules/cjs/loader.js:790:14)
 @ multi ../node_modules/error-overlay-webpack-plugin/lib/entry-basic.js ../node_modules/error-overlay-webpack-plugin/lib/entry-devserver.js? ../node_modules/webpack-dev-server/client?http://localhost:3333 ../node_modules/webpack/hot/dev-server.js ./.xconsole/index.js index[4]
ℹ 「wdm」: Failed to compile.
@Boelroy
Copy link
Collaborator

Boelroy commented Oct 28, 2021

删除 node_modules 重装一下试试。 感觉应该是装包失败了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants