Skip to content

pBouillon/zed-angular-language-server

Repository files navigation

Angular Language Server Zed Extension

Angular template support for Zed, powered by the Angular Language Service.

Features

  • Completions, diagnostics, hover info, and go-to-definition via the Angular Language Service
  • Syntax highlighting for bindings, control flow, directives, and interpolations
  • TypeScript highlighting and completions injected into binding expressions and interpolations
  • Code outline listing elements, control flow blocks, defer blocks, and template variables
  • Auto-indentation for HTML elements and control flow blocks

Configuration

Add the following to your Zed settings.json to customize the extension:

{
  "lsp": {
    "angular-language-server": {
      "initialization_options": {
        "force_strict_templates": true,
        "suppress_angular_diagnostic_codes": ["-998113"]
      }
    }
  }
}
Option Type Default Description
force_strict_templates boolean false Force-enables strict template type-checking, overriding your tsconfig.
suppress_angular_diagnostic_codes string[] [] List of Angular diagnostic codes to suppress, e.g. ["-998113"]. The code for a diagnostic is shown in parentheses when hovering over it in the editor.

Getting Started

  1. Clone this repository
  2. Add your changes
  3. Open Zed, navigate to the extension window and click on Install Dev Extension
  4. Select the folder in which is placed the extension.toml

Contributing

Pull requests are welcome. For significant changes, open a discussion first to align on the approach. Please ensure cargo fmt and cargo clippy pass before submitting.

Reporting a Bug

Open a GitHub issue and include:

  • A minimal template that reproduces the problem
  • What you expected vs. what happened
  • If you're willing to help fixing it

Feature Requests

Open a GitHub issue describing the use case, or submit a pull request directly.

Credits

This extension would not exist without the prior work done in nathansbradshaw/zed-angular.

About

Angular template support for Zed, powered by the Angular Language Service.

Topics

Resources

License

Stars

Watchers

Forks

Contributors