Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>NestedTextNew to Visual Studio Code? Get it now.
NestedText

NestedText

Boris Marković

|
694 installs
| (2) | Free
NestedText data format extension
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

NestedText data format extension for Visual Studio Code

NestedText version

Visual Studio Code extension that provides both strict and lax syntax highlighting grammars for the NestedText data format.

Preview

Features

  • Strict highlighting: Implements the canonical NestedText file format rules.
  • Lax highlighting: A more permissive grammar that accepts a wider range of leading whitespace.
  • File associations: Recognizes .nt files (and other configured extensions) for highlighting.
  • Lightweight: Token-based grammar suitable for quick editing and large files.

Installation

  • From the VS Code Marketplace: search for "NestedText".
  • Or build and install locally:
npm install
npm run package
  • Then install the produced .vsix via "Extensions: Install from VSIX..." in VS Code

Usage

  • Open a file with a supported extension (for example note.nt) to enable syntax highlighting.
  • The extension activates on file open and applies token-based highlighting automatically.
  • Both strict and lax grammars are included. To switch grammars manually, use the language mode picker in the VS Code status bar and select the desired NestedText grammar.

Example

NestedText example content:

book:
  title: The Little Prince
  author: Antoine de Saint-Exupéry
  chapters:
    - Chapter 1
    - Chapter 2
  • Strict mode: only space characters are allowed where the spec requires them.
  • Lax mode: accepts other whitespace characters (tabs, etc.) before tokens.

Development

  • Install dependencies:
npm install
  • Build the grammar JSON (used by the extension):
npm run build
  • Run and debug the extension using the VS Code Debug panel (Launch Extension).

Contributing

  • Open issues for bugs or feature requests.
  • Fork, create a branch, and submit a Pull Request for changes.
  • Please include tests or samples when adding grammar changes.

License

MIT

Maintainer

  • Repository: https://github.com/bmarkovic17/nestedtext
  • Maintainer: Boris Marković

Changelog

2.2.1

  • Fixed issue with not being able to use colons in non-multiline dictionary keys
  • Fixed issue where multiline dictionary keys could not be indented
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft