Skip to content
This repository was archived by the owner on Aug 25, 2020. It is now read-only.

testthedocs/vscode-vale

 
 

Repository files navigation

VSCode vale

This extension is now depreciated in favour of github.com/errata-ai/vale-vscode, which supports both Vale CLI and Vale Server. You should uninstall this extension, and install that extension. Any Vale config and styles should work with no issue, but you will likely need to update any relevant settings in the new extension.

Thanks to all the work previous work from lunaryorn, this is a new maintained fork, with more features to come soon.

Lint documents with Vale in Visual Studio Code.

Prerequisites

Install vale 0.7.2 or newer.

If Vale is too old the extension fails to activate. In this case please update Vale; the error message tells you the required version.

By default the extension will use the global installed binary vale. In case you have the binary installed on a local project you can configure the extension to use the local path. See configuration options below.

Usage

Vale automatically checks a document when you open or save it. Use the Vale: Lint workspace command to check the entire workspace.

Vale always runs from the workspace directory in either case, so if you put a Vale configuration in the workspace directory it will automatically pick it up.

This extension supports the following file extensions by default, but you can change them with the vscode-vale.fileExtensions config item (see below):

  • Asciidoc: .adoc and .asciidoc
  • Markdown: .md and .markdown
  • reStructuredText: .rst
  • LaTeX: .tex
  • plain text: .txt

Configuration

  • vscode-vale.configPath: Absolute path to Vale config file. If not specified, uses normal Vale config scoping rules.
  • vscode-vale.path: (default vale). Absolute path to the vale binary, useful if you don't want to use the global binary.

Example

{
  // You can use ${workspaceFolder} it will be replaced by workspace folder path
  "vscode-vale.path": "${workspaceFolder}/node_modules/.bin/vale"

  // or use some absolute path
  "vscode-vale.path": "/some/path/to/vale"
}
  • vscode-vale.fileExtensions: (default md, markdown, txt, rst, tex, adoc, asciidoc).

File extensions to lint.

Note, these also need to be in your Vale config file.

Sponsor this project

Packages

No packages published

Languages

  • TypeScript 100.0%