-
Notifications
You must be signed in to change notification settings - Fork 127
/
document-the-code.hbs
30 lines (21 loc) · 1008 Bytes
/
document-the-code.hbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
Project Path: {{ absolute_code_path }}
Source Tree:
```
{{ source_tree }}
```
{{#each files}}
{{#if code}}
`{{path}}`:
{{code}}
{{/if}}
{{/each}}
I'd like you to add documentation comments to all public functions, methods, classes and modules in this codebase.
For each one, the comment should include:
1. A brief description of what it does
2. Explanations of all parameters including types/constraints
3. Description of the return value (if applicable)
4. Any notable error or edge cases handled
5. Links to any related code entities
Try to keep comments concise but informative. Use the function/parameter names as clues to infer their purpose. Analyze the implementation carefully to determine behavior.
Comments should use the idiomatic style for the language, e.g. /// for Rust, """ for Python, /** */ for TypeScript, etc. Place them directly above the function/class/module definition.
Let me know if you have any questions! And be sure to review your work for accuracy before submitting.