Skip to content

Add short description and example re annotation in Completions Files #121

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 7 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion docs/reference/completions.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ is identical to the `contents`:
{ "trigger": "foo\ttest", "contents": "foobar" }
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest to add the separate annotation form as a direct example here.

```

**trigger**
**trigger** and **annotation**
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This definition should only be about trigger.

: Text that will be displayed in the completions list
and will cause the `contents`
to be inserted when chosen.
Expand All @@ -93,6 +93,12 @@ is identical to the `contents`:
slightly grayed
and does not affect the trigger itself.

Annotations can also be defined using `annotation`:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be in a separate annotation definition that mentions the version this was added in.


```json
{ "trigger": "foo", "annotation": "test", "contents": "foobar" }
```

**contents**
: Text to be inserted in the buffer.
Supports the same string interpolation features
Expand Down