navidnabavi

navidnabavi / styl

Public

A fast, opinionated linter, validator, and formatter for Mapbox GL and MapLibre GL style JSON files.

11
0
100% credibility
Found May 13, 2026 at 11 stars -- GitGems finds repos before they trend. Get early access to the next one.
Sign Up Free
AI Analysis
Rust
AI Summary

styl is a command-line linter, validator, and formatter for JSON style files used in Mapbox GL and MapLibre GL mapping libraries.

How It Works

1
🗺️ Crafting your custom map

You're designing a beautiful interactive map and have a special file that describes its layers, colors, and data sources.

2
🔍 Discover styl helper

You learn about styl, a friendly tool that checks your map design file for mistakes, gives tips, and makes it look neat.

3
📥 Set up the tool

You quickly add the tool to your computer with a simple download, and it's ready to help right away.

4
Run the check

You point the tool at your map design file, and in seconds it scans everything, spotting errors, warnings, and smart suggestions.

5
💡 See easy fixes

Clear notes pop up explaining issues like hidden layers or unused data, with simple hints to make your map better.

6
✏️ Apply changes

You tweak your file using the tips, then tidy it up so everything is perfectly organized and consistent.

🎉 Flawless map ready!

Your map design file is now error-free, optimized, and beautifully arranged, bringing your map to life perfectly.

Sign up to see the full architecture

5 more

Sign Up Free

Star Growth

See how this repo grew from 11 to 11 stars Sign Up Free
Repurpose This Repo

Repurpose is a Pro feature

Generate ready-to-use prompts for X threads, LinkedIn posts, blog posts, YouTube scripts, and more -- with full repo context baked in.

Unlock Repurpose
AI-Generated Review

What is styl?

styl is a Rust CLI tool for linting, validating, and formatting JSON style files used in Mapbox GL and MapLibre GL maps. It spots spec errors like missing sources or invalid properties, flags best practices such as duplicate layer IDs, invisible layers, or deep expressions, and reformats with canonical key order. Run `styl check style.json` for diagnostics in human, JSON, or GitHub Actions formats, with stdin support and `.mapboxlintrc` configs.

Why is it gaining traction?

Its Rust speed shines in fast GitHub Actions CI via annotations and `--check` modes, outpacing JS alternatives for large styles. Opinionated rules hit map-specific pain points like legacy filters, unused sources, or z-order issues, plus formatter enforces consistency without generic JSON tools. GitHub fast runners make it a drop-in for style workflows.

Who should use this?

MapLibre GL devs tweaking styles in editors or scripts, teams with complex layers fighting perf hints like empty text-fields or zero dasharrays. Frontend map builders using fast GitHub search for validation in PRs, or stylus-like tools generating styles needing quick checks.

Verdict

Worth cargo installing for MapLibre work—thorough docs, CLI, and tests despite 11 stars and 1.0% credibility. Early stage means fewer rules than mature linters, but fast GitHub integration makes it production-ready for style hygiene today.

(198 words)

Sign up to read the full AI review Sign Up Free

Similar repos coming soon.