-
Notifications
You must be signed in to change notification settings - Fork 120
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
找不到名称“process” #2072
Comments
报错信息已经很明确了 |
我是用的pnpm,执行 console报错, 有在src目录下配置 |
.env 文件放在项目根目录下哈,不是 src 下 |
已放置在根目录下,还是提示 |
要 PUBLIC_ 开头的自定义环境变量才可以在 client 代码中访问,你看下文档介绍 |
改成PUBLIC_ 开头,可以读取到了,感谢指导! |
Version
Details
const baseURL = process.env.PUBLIC_BASE_URL ?? "";
找不到名称“process”。是否需要安装 Node.js 的类型定义? 请尝试运行
npm i --save-dev @types/node
。Reproduce link
none
Reproduce Steps
none
The text was updated successfully, but these errors were encountered: