gmisail / Nice

A static site generator that is not mean.
MIT License
25 stars 3 forks source link

Convert configuration files from JSON to YAML #4

Closed gmisail closed 4 years ago

gmisail commented 4 years ago

YAML is a much easier language to pick up compared to JSON, so it would make most sense to implement the configuration file using it.

Before

  "assetsPath": "_assets",
  "postsPath": "_posts",
  "pagesPath": "_pages",
  "layoutsPath": "_layouts",
  "outputPath": "_public",

  "variables": {
    "title": "john site",
    "name": {
      "first": "John",
      "last": "Smith"
    }
  }
}

After

paths:
     assets: _assets
     posts: _posts
     pages: _pages
     layouts: _layouts
     output: _public
variables:
     title: john's site
     name:
          first: john
          last: smith