query

Experimental

针对你的 monorepo 运行 GraphQL 查询。

¥Run GraphQL queries against your monorepo.

Terminal
turbo query [query] [flags]

未传递任何参数时,该命令将打开 GraphiQL 测试环境来运行查询。

¥When no arguments are passed, the command will open a GraphiQL playground to run queries.

Terminal
turbo query

传递查询字符串时,该命令将运行查询并输出结果。

¥When passed a query string, the command will run the query and output the results.

Terminal
turbo query "query { packages { items { name } } }"

传递文件路径时,该命令将读取文件并运行查询。

¥When passed a file path, the command will read the file and run the query.

Terminal
turbo query query.gql