JSONL
JSON Lines (JSONL) syntax highlighting support for Zed
How to install
With Forge Super installed, the button above opens the app on this extension, where you press Install. Nothing is installed until you do.
You can also open the Extensions panel in the app and search for JSONL. The extension's id is jsonl.
Don't have Forge Super yet? Download it here.
README
From the extension's repository, written by its authors and not by Mentenaz. See the source.
JSONL Syntax - Zed Extension
A Zed editor extension that provides syntax highlighting for JSON Lines (JSONL) and Newline Delimited JSON (NDJSON) files.
Overview
JSON Lines is a format for storing structured data with one JSON object per line. Each line is a valid JSON value, making it suitable for streaming and processing large datasets.
{"name": "John", "age": 30}
{"name": "Jane", "age": 25}
{"name": "Bob", "age": 35}
Features
- Syntax highlighting for
.jsonland.ndjsonfiles - Automatic file detection
- Tree-sitter JSON parser for accurate highlighting
- 2-space indentation default
- Performance optimized for large files
Installation
Development Installation
-
Clone this repository:
git clone https://github.com/[your-username]/jsonl-syntax cd jsonl-syntax -
In Zed, open command palette (
Cmd+Shift+P/Ctrl+Shift+P) -
Run "zed: install dev extension" and select the
jsonl-syntaxfolder
Usage
Open any .jsonl or .ndjson file in Zed to see syntax highlighting automatically applied.
Development
Project Structure
jsonl-syntax/
├── extension.toml # Extension configuration
├── languages/
│ └── jsonl/
│ ├── config.toml # Language settings
│ └── highlights.scm # Highlighting rules
├── sample.jsonl # Test file
└── validate.py # Validation script
Making Changes
- Edit highlighting rules in
languages/jsonl/highlights.scm - Modify language settings in
languages/jsonl/config.toml - Reload extensions in Zed: "zed: reload extensions"
- Test changes with sample files
Contributing
Contributions are welcome.
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
Technical Details
This extension uses the tree-sitter-json grammar for parsing. Each JSONL line is treated as a separate JSON document for highlighting purposes.
License
MIT License - see LICENSE file for details.