query
On this page

importJSON

lib.trivial.importJSON

Docs pulled from | This Revision | 16 minutes ago


Reads a JSON file.

Examples

lib.trivial.importJSON usage example

example.json

{
  "title": "Example JSON",
  "hello": {
    "world": "foo",
    "bar": {
      "foobar": true
    }
  }
}
importJSON ./example.json
=> {
  title = "Example JSON";
  hello = {
    world = "foo";
    bar = {
      foobar = true;
    };
  };
}

Inputs

path

1. Function argument

Type

importJSON :: path -> any

Noogle also knows

Aliases