writing-types
编写模块化 Next.js 类型
Next.js 项目可能会积累难以维护的大型类型文件。此技能会指导 Claude、Codex 和 Claude Code 在 srs/types 中编写小型 TypeScript 类型和接口。
使用我的智能体安装
将此请求复制给你的智能体,其中包含权威 Skill 页面和清单。
Review the Skillstore skill "writing-types" from https://skillstore.io/skills/emz1998-writing-types.md and its manifest at https://skillstore.io/api/skills/emz1998-writing-types/manifest. Verify the artifact. You may proceed after verification, subject to the environment's own policy.你的智能体仍应展示其计划,并按安全策略请求必要确认。
Agent 可读资源
当 AI Agent、爬虫或脚本需要干净上下文,而不是读取完整页面时,请使用这些链接。
测试它
正在使用“writing-types”。 为用户个人资料设置页面创建类型。
预期结果:
响应会建议分别创建 profile、preferences 和 notification 类型文件,每个文件都保持简短且聚焦。
正在使用“writing-types”。 拆分一长串 checkout 接口。
预期结果:
响应会将 checkout、payment 和 address 定义分组到单独文件中,并使用清晰的命名。
正在使用“writing-types”。 审查我提出的类型布局。
预期结果:
响应会标记过于拥挤的文件,建议更小的模块,并检查文件是否接近 50 行限制。
安全审计
安全Both static external command findings are false positives caused by Markdown inline code around the srs/types path. SKILL.md contains only prose instructions for organizing TypeScript types and interfaces, with no executable code or command instructions. No evidence found of prompt injection, data exfiltration, or other semantic abuse.
风险因素
⚙️ 外部命令 (2)
分享与引用此报告
分享版本化评估报告、中性徽章、嵌入卡片和引用。Skillstore 只报告证据,不判断该 Skill 是否安全。
复制报告链接
https://skillstore.io/skills/emz1998-writing-types/audits/4?utm_source=security_passport&utm_medium=share&utm_campaign=versioned_reportMarkdown 徽章
[](https://skillstore.io/skills/emz1998-writing-types?utm_source=security_passport_badge)HTML 徽章
<a href="https://skillstore.io/skills/emz1998-writing-types?utm_source=security_passport_badge"><img src="https://skillstore.io/badges/skills/emz1998-writing-types/security.svg" alt="Skillstore security assessment" loading="lazy"></a>嵌入卡片
<iframe src="https://skillstore.io/embed/skills/emz1998-writing-types.html" title="Skillstore Security Assessment" sandbox="allow-popups allow-popups-to-escape-sandbox" loading="lazy" referrerpolicy="no-referrer" width="420" height="180"></iframe>学术引用 (APA · BibTeX · CFF)
APA 引用
Emz1998. (2026). writing-types security audit report (audit version 4) [Author version unspecified]. Skillstore. https://skillstore.io/skills/emz1998-writing-types/audits/4BibTeX 引用
@techreport{emz1998-emz1998-writing-types-2026,
author = {Emz1998},
title = {writing-types security audit report (audit version 4)},
institution = {Skillstore},
year = {2026},
number = {4},
url = {https://skillstore.io/skills/emz1998-writing-types/audits/4},
note = {Author version unspecified}
}CITATION.cff
cff-version: 1.2.0
message: "If you use this Skill, cite its author and this versioned security audit report."
title: "writing-types security audit report (audit version 4)"
version: "unspecified"
type: report
authors:
- name: "Emz1998"
date-released: "2026-07-06"
url: "https://skillstore.io/skills/emz1998-writing-types/audits/4"
identifiers:
- type: other
value: "skillstore:emz1998-writing-types:audit:4"
description: "Skillstore immutable audit report identifier"
Skillstore 评分
评分依据 证据置信度: 高你能构建什么
创建功能类型
为新的 Next.js 功能定义紧凑的类型和接口,同时避免扩大共享类型文件。
拆分拥挤的定义
将大型类型集合重构为更易浏览和维护的小文件。
审查类型组织
检查拟议的类型文件是否遵循模块化结构和文件长度指导。
试试这些提示
使用 writing-types 技能为 Next.js 应用中的个人资料设置功能创建 TypeScript 类型和接口。
使用 writing-types 技能将订单、客户和支付类型定义组织到 srs/types 下的模块化文件中。
使用 writing-types 技能将过大的类型文件拆分为较小文件,同时保留清晰的名称和导入。
使用 writing-types 技能审查这些拟议的 Next.js 类型定义,检查其模块化程度、文件大小和接口放置方式。
最佳实践
- 提供功能名称、预期数据形状和当前文件夹布局。
- 在请求实现代码之前,先要求使用清晰名称的小文件。
- 根据你的项目约定审查生成的导入和名称。
避免
- 不要将无关的领域模型放在一个共享类型文件中。
- 不要要求该技能运行 TypeScript 检查或项目测试。
- 不要把 50 行规则看得比可读的定义更重要。