返回 Skill 列表
extension
分类: 开发与工程无需 API Key

cairo-modules-files

解释Cairo模块如何跨文件和文件夹拆分,以及`mod`声明如何映射到文件;当请求涉及将模块组织到多个Cairo文件中时使用。

person作者: jakexiaohubgithub

Cairo Modules in Files

Overview

Explain how module declarations map to files and folders in a Cairo package.

Quick Use

  • Read references/modules-files.md before answering.
  • Show the relationship between mod declarations and file names.
  • Remind that use does not load modules; only mod does.

Response Checklist

  • Declare a module with mod name; in the parent file.
  • Place the module body in name.cairo or name/mod.cairo.
  • Declare submodules in the module file and place them in name/submodule.cairo.

Example Requests

  • "Where should I put mod hosting;?"
  • "How do I split a module into multiple files?"
  • "Why doesn't use load my module?"

Cairo by Example