Skip to content

Commit

Permalink
Merge branch 'master' into use-server-command
Browse files Browse the repository at this point in the history
  • Loading branch information
octref authored Aug 14, 2020
2 parents 63607e4 + 7431ed1 commit a0b499b
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 7 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
- Component Data doesn't work if it comes from devDependencies. #2132.
- 🙌 Add support for analyzing vue-class-component and vue-property-decorator. Thanks to contribution from [@yoyo930021](https://github.com/yoyo930021). #864, #1105 and #1323.
- 🙌 Remove lsp client commands for improve third party lsp client. Thanks to contribution from [@yoyo930021](https://github.com/yoyo930021). #2137.
- 🙌 Fix "Go to definition" for methods/computeds does not work in the template. Thanks to contribution from [@cereschen](https://github.com/cereschen). #1484 and #2161.

### 0.26.1 | 2020-08-07 | [VSIX](https://marketplace.visualstudio.com/_apis/public/gallery/publishers/octref/vsextensions/vetur/0.26.1/vspackage)

Expand Down
6 changes: 3 additions & 3 deletions docs/intellisense.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,14 @@ Vetur should be able to resolve external modules and provide IntelliSense for th

For example, `vue` packages type definition in its module, so

- `npm i -S vue`
- `npm i -S vue` or `yarn add vue`
- `import Vue from 'vue'`
- `Vue.` should prompt IntelliSense for Vue.

`lodash` doesn't package type definition with it, but there is `@types/lodash` that has type definition for `lodash`, so

- `npm i -S lodash`
- `npm i -D @types/lodash`
- `npm i -S lodash` or `yarn add lodash`
- `npm i -D @types/lodash` or `yarn add -D @types/lodash`
- `import * as _ from 'lodash'`
- `_.` should prompt IntelliSense for lodash.

Expand Down
1 change: 1 addition & 0 deletions docs/vti.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ VTI (Vetur Terminal Interface) is a CLI that exposes some of Vetur's language fe

```bash
npm i -g vti
# or yarn global add vti
# run this in the root of a Vue project
vti
vti diagnostics
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"watch:build": "tsc -b -w .",
"copy:snippets": "node ./build/copy-snippets.js",
"lint": "tslint -c tslint.json client/**/*.ts server/**/*.ts scripts/**/*.ts",
"test:server": "npm run compile && cd server && npm test",
"test:server": "yarn compile && cd server && yarn test",
"test:e2e": "node ./dist/test/codeTestRunner.js",
"test:grammar": "node ./dist/test/codeTestRunner.js grammar",
"test:lsp": "node ./dist/test/codeTestRunner.js lsp",
Expand Down
2 changes: 2 additions & 0 deletions server/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ There are two ways to integrate `vls` into editors:

```bash
npm install vls -g
# or yarn global add vls
```

This will provide you the global `vls` command.
Expand All @@ -39,6 +40,7 @@ There are two ways to integrate `vls` into editors:
```bash
npm install vls --save
# or yarn add vls
```
Then, require the vls, this would typically look like:
Expand Down
2 changes: 1 addition & 1 deletion server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,6 @@
"test": "mocha",
"coverage": "nyc report --reporter=text-lcov > coverage.lcov && codecov",
"newVersion": "yarn version --new-version patch -m \"vls %s\"",
"preversion": "npm run compile && npm test"
"preversion": "yarn compile && yarn test"
}
}
5 changes: 3 additions & 2 deletions server/src/modes/template/interpolationMode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import { IServiceHost } from '../../services/typescriptService/serviceHost';
import { languageServiceIncludesFile } from '../script/javascript';
import { getFileFsPath } from '../../utils/paths';
import { mapBackRange, mapFromPositionToOffset } from '../../services/typescriptService/sourceMap';
import { URI } from 'vscode-uri';
import * as ts from 'typescript';
import { T_TypeScript } from '../../services/dependencyService';
import * as _ from 'lodash';
Expand Down Expand Up @@ -294,7 +295,7 @@ export class VueInterpolationMode implements LanguageMode {
: convertRange(definitionTargetDoc, r.textSpan);

definitionResults.push({
uri: definitionTargetDoc.uri.toString(),
uri: URI.file(definitionTargetDoc.uri).toString(),
range
});
}
Expand Down Expand Up @@ -342,7 +343,7 @@ export class VueInterpolationMode implements LanguageMode {
: convertRange(referenceTargetDoc, r.textSpan);

referenceResults.push({
uri: referenceTargetDoc.uri.toString(),
uri: URI.file(referenceTargetDoc.uri).toString(),
range
});
}
Expand Down
1 change: 1 addition & 0 deletions vti/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ VTI is a CLI that exposes some of Vetur's language features:

```bash
npm i -g vti
# or yarn global add vti
# In your Vue project root
vti diagnostics
```

0 comments on commit a0b499b

Please sign in to comment.