vanilla-lang
v1.5.3
Published
Elegant json-like configuration language
Downloads
4
Maintainers
Readme
Vanilla
Vanilla is a elegant json inspired configuration/markup language
Differences
Types: numbers, strings, booleans, null, objects
Rules
- The language can only go 3 layers down (root -> object/variable/array -> array/variable)
- Objects, variables, arrays can not contain an item of the same type, recursion does not exist
- Arrays can not contain variables only values
- Mixins can only be used in variables
Installation
npm install -g vanilla-lang
Usage
root
@test "this is a mixin"
'this is a example comment'
'this is a example
multiline comment'
user
password @test
inventory
- "item 1"
- "item 2"
- "item 3"
In the javascript code:
const vanilla = require("vanilla-lang");
const config = vanilla.load("config.va");
console.log(config.user);