rust/editors/code
bors 8a2331450a Auto merge of #15728 - EliasHolzmann:feature/local_documentation_vscode, r=Veykril
feat: vscode: Support opening local documentation if available

This PR implements the VS code support for opening local documentation (server side support was already implemented in #14662).

[local_docs.webm](https://github.com/rust-lang/rust-analyzer/assets/9659253/715b84dd-4f14-4ba0-a904-749b847eb3d5)

Displaying local instead of web docs can have many benefits:
- the web version may have different features enabled than locally selected
- the standard library may be a different version than is available online
- the user may not be online and therefore cannot access the web documentation
- the documentation may not be available online at all, for example because it is for a new feature in a library the user is currently developing

If the documentation is not available locally, the extension still falls back to the web version.

Closes #12867.

-----

If my implementation isn't really idiomatic TypeScript: Sorry, I'm not much of a TypeScript developer. I am open to feedback, however.
2023-10-10 06:33:10 +00:00
..
src vscode: Support opening local documentation if available 2023-10-09 20:11:53 +02:00
tests editor/code: Re-apply code format 2023-07-13 22:44:29 +09:00
.eslintignore vscode extension: use esbuild instead of rollup. 2021-08-10 10:18:08 +01:00
.eslintrc.js editor/code: Update typescript-eslint to v6 2023-07-13 22:44:29 +09:00
.gitignore Add experimental VSCode api 2022-03-04 07:45:51 +02:00
.prettierignore prettier config 2022-05-17 18:12:49 +01:00
.prettierrc.js prettier config 2022-05-17 18:12:49 +01:00
.vscodeignore Remove markdown injection 2023-06-23 11:31:10 +02:00
icon.png Extension icon 2020-01-15 16:07:39 +01:00
language-configuration.json feat: add backtick to surrounding and auto-closing pairs 2023-09-26 06:36:37 +00:00
LICENSE Add LICENSE file to make vsce happy 2021-12-04 12:29:27 +02:00
package-lock.json vscode: change minimum VS Code version to 1.75 from 1.78 2023-07-24 11:24:24 -04:00
package.json Addressed PR style comments 2023-10-09 02:15:05 -05:00
ra_syntax_tree.tmGrammar.json prettier run 2022-05-17 18:15:06 +01:00
README.md Improve extension description and README 2022-05-13 18:15:33 +02:00
tsconfig.eslint.json prettier run 2022-05-17 18:15:06 +01:00
tsconfig.json editor/code: Add FIXME comments for TS' --exactOptionalPropertyTypes option 2023-07-10 23:39:08 +09:00

rust-analyzer

This extension provides support for the Rust programming language. It is recommended over and replaces rust-lang.rust.

Features

Quick start

  1. Install rustup.
  2. Install the rust-analyzer extension.

Configuration

This extension provides configurations through VSCode's configuration settings. All configurations are under rust-analyzer.*.

See the manual for more information on VSCode specific configurations.

Communication

For usage and troubleshooting requests, please use the "IDEs and Editors" category of the Rust forum.

Documentation

See rust-analyzer.github.io for more information.