repo_description: Smarter YAML front matter parser, used by metalsmith, Gatsby, Netlify, Assemble, mapbox-gl, phenomic, vuejs vitepress, TinaCMS, Shopify Polaris, Ant Design, Astro,  hashicorp, garden, slidev, saber, sourcegraph, and many others. Simple to use, and battle tested. Parses YAML by default but can also parse JSON Front Matter, Coffee Front Matter, TOML Front Matter, and has support for custom parsers. Please follow gray-matter's author: https://github.com/jonschlinkert
repo_topics: assemble config data front-matter front-matter-parsers frontmatter gatsby javascript jonschlinkert mapbox markdown matter metalsmith netlify node nodejs parse phenomic yaml
code: 'use strict';
  
  const engines = require('./engines');
  const utils = require('./utils');
  
  module.exports = function(options) {
    const opts = Object.assign({}, options);
  
    // ensure that delimiters are an array
    opts.delimiters = utils.arrayify(opts.delims || opts.delimiters || '---');
    if (opts.delimiters.length === 1) {
      opts.delimiters.push(opts.delimiters[0]);
    }
  
    opts.language = (opts.language || opts.lang || 'yaml').toLowerCase();
    opts.engines = Object.assign({}, engines, opts.parsers, opts.engines);
    return opts;
  };
  