Skip to content
This repository was archived by the owner on Apr 14, 2022. It is now read-only.

Use TextDocumentClientCapabilities for documentation kind decision #319

Closed
jakebailey opened this issue Oct 29, 2018 · 3 comments
Closed

Comments

@jakebailey
Copy link
Member

We have a custom option to set the preferred documentation kind in initializationOptions, but the LS spec provides a way to do this in TextDocumentClientCapabilities:

completionItem?: {
	// ...

	/**
	 * Client supports the follow content formats for the documentation
	 * property. The order describes the preferred format of the client.
	 */
	documentationFormat?: MarkupKind[];

	// ...
}

Additionally, MarkupKind is duplicated, and the logic for choosing which to use seems to be reimplemented in a few different places that produce MarkupContent.

@MikhailArkhipov
Copy link

Yeah, we pass it in init b/c that's the way VS has been doing it. Markdown == VSC, plain text == VS. This can be part of the PTVS update item #32 .

@jakebailey
Copy link
Member Author

Yup, I wasn't sure how this would fit with VS, considering that it doesn't actually communicate over RPC. We seem to do a lot of stuff with settings in the language server init/settings change RPC handlers that I wish were placed elsewhere to be more consistent/testable (not to mention the duplication of many structs between the analyzer and LS).

@jakebailey
Copy link
Member Author

Closing in favor of #608.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants