YAML

Supported extensions: yaml, yml You can import yaml files into your js like this import data from './filename.yaml'.

Example file structure:

.
├── package.json
└── src
    ├── data.yaml
    └── index.js
# data.yaml

hello:
  - world
  - computer
// index.js

import data from './data.yaml'
console.log(data.hello[0]);

// "world"

Help us improve the docs

If something is missing or not entirely clear, please file an issue on the website repository or edit this page.