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

[BABEL] Note: The code generator has deoptimised the styling of internal\siteData.js as it exceeds the max of 500KB. #3003

Open
MyAccGit opened this issue Feb 16, 2022 · 7 comments

Comments

@MyAccGit
Copy link

[BABEL] Note: The code generator has deoptimised the styling of ……\node_modules@vuepress\core.temp\internal\siteData.js as it exceeds the max of 500KB.

操作步骤:
1、新建英文目录
2、终端执行 yarn add -D vuepress,设置配置文件
3、在根目录下创建docs
4、创建MD文档,N个
5、执行 yarn docs:build 时报如上错误。

只要MD文件多到一定程度后,就会出现此问题。
网上搜索了各种方法尝试,均未能成功。
恳请老师能予以指导,具体如何处理这个问题?

搜索网上有指导如下方法的,但参考设置后,仍报前述错误,没有解决。
`
在项目的根目录下找到 .babelrc 文件,增加 "compact": false ,如:

{
"compact": false,
"presets": ["env", "react", "stage-0"],
"plugins": [
"transform-runtime"
]
}
如果不存在则手动创建该文件,并填写内容如:

{
"compact": false
}
`

@coderup2021
Copy link

I have the save problem, have you solved it?

@StarCoderLn
Copy link

我也遇到这个问题了,请问你解决了吗

@MyAccGit
Copy link
Author

MyAccGit commented Oct 11, 2022 via email

@wodepig
Copy link

wodepig commented Mar 9, 2023

没解决可是一直启动不成功啊

@sr2ds
Copy link

sr2ds commented Mar 29, 2023

I have the same issue, in my case the website have more than 800 posts

@ReturnTmp
Copy link

我在这个 issue 中提到如何解决,希望对大家有帮助
I tried to handle this problem in this issue, hoping that it will help you.

issue: xugaoyi/vuepress-theme-vdoing#694

@Liu-code3
Copy link

需要创建babel.config.js这个文件,babel官网地址配置文件说明 https://babeljs.io/docs/config-files,希望对您有帮助!

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

7 participants