SuperAPI AI 工具集

faststore-storefront

通用与其它

查看项目

更新于 10-16 07:21

技能介绍

用途:为 VTEX FastStore 店面开发提供统一的编码规则与工作流,覆盖设计、调试、重构与解释代码等任务。主要能力与规则:使用 TypeScript 与 React 18,遵循 FastStore 框架架构;不得直接调用 Next.js API,禁止引入未要求的依赖,不读写 .faststore/ 目录。组件覆盖必须用 @faststore/core 的 getOverriddenSection,UI 组合优先使用 @faststore/ui;区块键以 cms/faststore/components/*.jsonc 的 $componentKey 与 src/components/index.tsx 默认导出的对象键一致为准,schema.json 为生成文件不得手改。样式须用 .scss,禁止全局 SCSS,需以包装类与 SCSS Modules 组织,@faststore/ui 样式导入需嵌套在局部类内。使用方式:安装全局 VTEX CLI,用 faststore cms-sync 同步 CMS schema,可加 --dry-run 只生成不上传;手动回退为 vtex content generate-schema 与 vtex content upload-schema。创建文件前需用 ls 确认目录与文件不存在。上传为交互式,store ID 取 discovery.config.js 的 contentSource.project。上传仅注册区块定义,区块还需在 Admin → Storefront → Content 添加到页面内容才生效。适用场景:FastStore 店面开发、区块覆盖、CMS 区块注册、样式与 GraphQL 扩展。限制:未提供具体版本价格、效果数据与完整 API 清单,需按需查阅项目内引用文件。