priority -> yieldTo for drop/paste API proposals (#189881)

Move await from `priority` for drop/paste API proposals

For #179430, #30066

Switching to use `yieldTo` instead of `priority` to let an extension de-rank itself in the list of edits. `priority` was an arbitrary number while `yieldTo` gives more control over how the ranking takes place
This commit is contained in:
Matt Bierner
2023-08-07 18:32:03 -07:00
committed by GitHub
parent 4f66a0c2c1
commit 39df243d21
14 changed files with 124 additions and 88 deletions

View File

@@ -83,7 +83,7 @@ export enum PasteUrlAsFormattedLink {
Never = 'never'
}
export async function getPasteUrlAsFormattedLinkSetting(document: vscode.TextDocument): Promise<PasteUrlAsFormattedLink> {
export function getPasteUrlAsFormattedLinkSetting(document: vscode.TextDocument): PasteUrlAsFormattedLink {
return vscode.workspace.getConfiguration('markdown', document).get<PasteUrlAsFormattedLink>('editor.pasteUrlAsFormattedLink.enabled', PasteUrlAsFormattedLink.Smart);
}