Your goal is to update any vulnerable dependencies.
Do the following:
1.Run `npm audit` to find vulnerable installed packages in this project
2.Run `npm audit fix` to apply updates
3.Run tests and verify the updates didn't break anything
claude mcp list # 查看当前配置的 MCP 服务器claude mcp add playwright npx @playwright/mcp@latest # 安装 playwright 服务,Playwright 提供控制浏览器的能力# Open the browser and navigate to localhost:3000claude mcp remove playwright # 移除配置
importanyiofromclaude_code_sdkimportqueryasyncdefmain():prompt="Hello, Claude! Tell me a joke."asyncformessageinquery(prompt):print(message)anyio.run(main)# cli: claude -p "Hello, Claude! Tell me a joke."
Yaml前置标记 descriptio字段:何时使用该技能和 name字段:名字,disable-model-invocation:可选,以防止 Claude 自动触发。还支持技能内容中动态值的字符串替换,比如能传递参数 $ARGUMENTS。
markdown内容包含技能调用要遵循的指令。
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
---
name: explain-code
description: Explains code with visual diagrams and analogies. Use when explaining how code works, teaching about a codebase, or when the user asks "how does this work?"
disable-model-invocation: true # 禁止自动调用
allowed-tools: ["Read", "Grep"] # 限制可用工具
context: fork # 在子代理中运行
---
When explaining code, always include:
1.**Start with an analogy**: Compare the code to something from everyday life
2.**Draw a diagram**: Use ASCII art to show the flow, structure, or relationships
3.**Walk through the code**: Explain step-by-step what happens
4.**Highlight a gotcha**: What's a common mistake or misconception?
Keep explanations conversational. For complex concepts, use multiple analogies.
#1. 计划模式 进行探索:Claude 阅读文件并回答问题,无需更改文件。#2. Create a plan. 按 Ctrl+G 在文本编辑器中打开计划,直接编辑,然后 Claude 继续。I want to add xxxx. What files need to change? What's the session flow? Create a plan.
#3. 切回普通模式,让claude 编码,并对照计划进行验证。implement the xxxx from your plan. write tests for the callback handler, run the test suite and fix any failures.
#4. commit提交 commit with a descriptive message and open a PR