Skip to content

Insert missing comma or colon before completion#185

Open
zardoy wants to merge 2 commits into
microsoft:mainfrom
zardoy:insert-prev-edit
Open

Insert missing comma or colon before completion#185
zardoy wants to merge 2 commits into
microsoft:mainfrom
zardoy:insert-prev-edit

Conversation

@zardoy

@zardoy zardoy commented Mar 24, 2023

Copy link
Copy Markdown
Contributor

Inspired by microsoft/TypeScript#52899
Fixes microsoft/vscode#69545 (but I don't know what to do with *when " is typed)

Though when I just implemented it, I was thinking of why do we need "insert missing colon" behavior: if property has suggestions : will be added as insert text anyway (but not always e.g. doesn't work with oneOf). But if property doesn't have suggestions, there is no way to trigger such behavior. So I think we should make property completions to always include : as insert case (there are no shorthands in JSON 😃)

@zardoy

zardoy commented Aug 5, 2023

Copy link
Copy Markdown
Contributor Author

@aeschli I've removed colon insertion, so I do hope the pr will be easier to review :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[json] add commas automatically

1 participant