Adds comments, makes it nicer to read and avoids comma mistakes.
For details see hjson.github.io.
Hjson syntax for VIM
License: MIT License
Adds comments, makes it nicer to read and avoids comma mistakes.
For details see hjson.github.io.
Doing gg=G
reveals the horrors of the broken indentation. I am unsure of wether it's a general issue or strictly an issue with NeoVim comparability.
NeoVim version: v0.10.0-dev
Syntax highlighting seems to change depending on where my cursor is in the file, which is ... strange, to say the least.
Tested on NVIM v0.10.0 and Vim 8.0. I see similar behavior on both, though the Vim 8.0 issue is subtly different, possibly due to different rerendering behavior.
NVIM v0.10.0
Vim 8.0
From the /try example on hjson.org, there is one section of output that looks odd in vim-hjson.
{
# commas are optional
commas:
{
one: 1
two: 2
}
}
The one: 1
part shows the number without highlighting. My vimrc has this in it:
hi clear Identifier
hi clear Statement
But that doesn't seem to explain 1
lacking highlighting.
Apparently, syntax highlighting assumes presence of commas between list elements, which are optional in hjson.
I expect a closing bracket (of a list or object) to be displayed in same colors as a corresponding opening bracket.
Instead, closing }
of some objects within a list AND the ]
of that list are highlighted rather like string literals (at least in my colorscheme). To be precise, wrong }
highlighting happens for objects:
According to https://hjson.github.io/try.html, this is a valid list of 6 elements โ 5 objects and 1 string:
[
{x:1}
{y:2} {z:3}
{z:4}
"You are in a debris room filled with stuff washed in from the surface."
{y:5}
]
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.