【问题标题】:how to run amplify codegen in where codegen is already configured?如何在已配置 codegen 的地方运行 amplify codegen?
【发布时间】:2021-07-30 09:35:33
【问题描述】:

我们有一个项目 repo,其中后端团队添加了新的 api。 其他开发人员已经运行并配置了放大和代码生成。 现在我想添加这些新查询及其类型。 当我运行放大代码生成时,出现此错误:

Please download the schema.graphql or schema.json and place in C:\leag\nevClon\newwebsite before adding codegen when not in an amplify project

当我运行 amplify add codegen 时,它说 Codegen 每个项目仅支持一个 GraphQL API。 有人可以指导我这样做的正确方法是什么。

【问题讨论】:

    标签: aws-amplify amplify graphql-codegen


    【解决方案1】:

    我过去曾见过这个问题。我尝试过的事情包括...

    1. 确保您处于正确的放大环境中。
    2. 运行放大拉取以确保您是最新的。
    3. 尝试使用amplify init重新初始化
    4. 当所有其他方法都失败时,请尝试重新克隆存储库。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2020-05-29
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2022-01-04
      • 1970-01-01
      • 2015-07-10
      相关资源
      最近更新 更多