writing-utils
编写模块化 Next.js 工具函数
当辅助函数缺乏结构地增长时,工具代码可能会变得难以复用。此技能指导 Claude、Codex 和 Claude Code 创建简短、模块化的 Next.js 工具函数。
使用我的智能体安装
将此请求复制给你的智能体,其中包含权威 Skill 页面和清单。
Review the Skillstore skill "writing-utils" from https://skillstore.io/skills/emz1998-writing-utils.md and its manifest at https://skillstore.io/api/skills/emz1998-writing-utils/manifest. Verify the artifact. You may proceed after verification, subject to the environment's own policy.你的智能体仍应展示其计划,并按安全策略请求必要确认。
Agent 可读资源
当 AI Agent、爬虫或脚本需要干净上下文,而不是读取完整页面时,请使用这些链接。
测试它
正在使用“writing-utils”。 Create helpers for formatting dates and trimming user names.
预期结果:
助手会提出单独的日期和文本工具文件,每个文件专注于一个职责并保持简短。
正在使用“writing-utils”。 Refactor one large utility file used by a dashboard.
预期结果:
助手会建议按格式化、验证和数据转换职责分组为更小的工具文件。
正在使用“writing-utils”。 Plan utilities for a Next.js notes feature.
预期结果:
助手会概述用于笔记标题、时间戳和显示格式的紧凑辅助函数,而不添加组件逻辑。
安全审计
安全The skill is prompt-only and contains no executable scripts, network calls, file operations, or environment access. Static analysis reported no suspicious patterns, and manual review found no prompt injection or malicious intent.
分享与引用此报告
分享版本化评估报告、中性徽章、嵌入卡片和引用。Skillstore 只报告证据,不判断该 Skill 是否安全。
复制报告链接
https://skillstore.io/skills/emz1998-writing-utils/audits/4?utm_source=security_passport&utm_medium=share&utm_campaign=versioned_reportMarkdown 徽章
[](https://skillstore.io/skills/emz1998-writing-utils?utm_source=security_passport_badge)HTML 徽章
<a href="https://skillstore.io/skills/emz1998-writing-utils?utm_source=security_passport_badge"><img src="https://skillstore.io/badges/skills/emz1998-writing-utils/security.svg" alt="Skillstore security assessment" loading="lazy"></a>嵌入卡片
<iframe src="https://skillstore.io/embed/skills/emz1998-writing-utils.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-utils security audit report (audit version 4) [Author version unspecified]. Skillstore. https://skillstore.io/skills/emz1998-writing-utils/audits/4BibTeX 引用
@techreport{emz1998-emz1998-writing-utils-2026,
author = {Emz1998},
title = {writing-utils security audit report (audit version 4)},
institution = {Skillstore},
year = {2026},
number = {4},
url = {https://skillstore.io/skills/emz1998-writing-utils/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-utils 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-utils/audits/4"
identifiers:
- type: other
value: "skillstore:emz1998-writing-utils:audit:4"
description: "Skillstore immutable audit report identifier"
Skillstore 评分
评分依据 证据置信度: 高你能构建什么
创建可复用的前端辅助函数
为常见的格式化、解析或浏览器端支持任务构建聚焦的工具函数。
组织应用工具文件
将工具函数拆分为小文件,使代码库更易于浏览。
保持辅助函数变更小而集中
要求助手在添加目标应用行为时保持工具文件简短。
试试这些提示
Create a utility function for my Next.js app that handles this task: [describe task]. Keep the file under 50 lines.
Create modular utility functions for [feature]. Split them into separate files when that makes the code easier to maintain.
Review these utility functions and suggest a modular file structure. Keep each file under 50 lines and preserve current behavior.
Design a utility layer for [Next.js app area]. Group helpers by responsibility and explain where each utility file should live.
最佳实践
- 在请求代码之前描述工具函数的用途和预期输入。
- 让每个辅助函数专注于一个职责。
- 当工具文件接近 50 行时,要求进行文件拆分。
避免
- 不要要求此技能构建完整页面或 UI 组件。
- 不要将无关的辅助函数合并到一个大型工具文件中。
- 不要将此技能作为项目测试的替代品。