Setup missing required ENV [Solved but needs update or PR]

未关闭
#417 1 条评论 2 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
1/5
预计耗时
1 小时以内
新手友好度
55/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
停滞
技术栈
nextjs, typescript
领域
web-dev

调研方向

先检查 nextjs.config.js 和 .env.example 文件。然后添加缺失的 BLOB_STORE_ID 示例值,再运行 yarn dev 以确认不再出现无效 next.config.js 选项错误。

由索引模型根据 Issue 内容生成。

描述

Hi!

[SOLVED BUT NEEDS A TINY CHANGE]

When installing from scratch, since the nextjs.config.js is adding an item that requires the BLOB_STORE_ID:

 {
    protocol: 'https',
    hostname: process.env.BLOB_STORE_ID,
  },

That ENV since to be present in the env.example.

Just adding any value to that will solve the problem, otherwise, running yarn dev will return in an error:

Invalid next.config.js options detected:
    "images.remotePatterns[11].hostname" is missing, expected string
See more info here: https://nextjs.org/docs/messages/invalid-next-config
error Command failed with exit code 1.

Solution (unless scaping that empty string in the config):

in .env (so from .env.example):

BLOB_STORE_ID=1234567890
主要语言
TypeScript
星标
643
派生
193
平均合并
17 小时 9 分钟
30 天内合并 PR
3

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

payloadcms/website 的其他 Issue

查看 payloadcms/website 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。