mirror of
https://github.com/Microsoft/vscode
synced 2024-08-27 21:09:43 +00:00
[html] update languageservice. Fixes #12954
This commit is contained in:
parent
a0f68bfe3f
commit
07bbf8bb4e
4
extensions/html/server/npm-shrinkwrap.json
generated
4
extensions/html/server/npm-shrinkwrap.json
generated
|
@ -3,9 +3,9 @@
|
|||
"version": "1.0.0",
|
||||
"dependencies": {
|
||||
"vscode-html-languageservice": {
|
||||
"version": "1.0.0-next.4",
|
||||
"version": "1.0.0-next.5",
|
||||
"from": "vscode-html-languageservice@next",
|
||||
"resolved": "https://registry.npmjs.org/vscode-html-languageservice/-/vscode-html-languageservice-1.0.0-next.4.tgz"
|
||||
"resolved": "https://registry.npmjs.org/vscode-html-languageservice/-/vscode-html-languageservice-1.0.0-next.5.tgz"
|
||||
},
|
||||
"vscode-jsonrpc": {
|
||||
"version": "2.4.0",
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
"node": "*"
|
||||
},
|
||||
"dependencies": {
|
||||
"vscode-html-languageservice": "^1.0.0-next.4",
|
||||
"vscode-html-languageservice": "^1.0.0-next.5",
|
||||
"vscode-languageserver": "^2.6.0-next.3",
|
||||
"vscode-nls": "^1.0.4"
|
||||
},
|
||||
|
|
|
@ -6,8 +6,9 @@
|
|||
|
||||
import { createConnection, IConnection, TextDocuments, InitializeParams, InitializeResult } from 'vscode-languageserver';
|
||||
|
||||
import { HTMLDocument, getLanguageService, CompletionConfiguration, HTMLFormatConfiguration } from 'vscode-html-languageservice';
|
||||
import { HTMLDocument, getLanguageService, CompletionConfiguration, HTMLFormatConfiguration, DocumentContext } from 'vscode-html-languageservice';
|
||||
import { getLanguageModelCache } from './languageModelCache';
|
||||
import * as url from 'url';
|
||||
|
||||
|
||||
import * as nls from 'vscode-nls';
|
||||
|
@ -116,7 +117,8 @@ connection.onDocumentRangeFormatting(formatParams => {
|
|||
|
||||
connection.onDocumentLinks(documentLinkParam => {
|
||||
let document = documents.get(documentLinkParam.textDocument.uri);
|
||||
return languageService.findDocumentLinks(document, workspacePath);
|
||||
let documentContext: DocumentContext = { resolveReference: ref => url.resolve(document.uri, ref) };
|
||||
return languageService.findDocumentLinks(document, documentContext);
|
||||
});
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue