Search results
Parses YAML front matter by default, but also has support for YAML, JSON, TOML or Coffee Front-Matter, with options to set custom delimiters. Used by metalsmith, assemble, verb and . Latest version: 4.0.3, last published: 3 years ago.
Parse front-matter from a string or file. Fast, reliable and easy to use. Parses YAML front matter by default, but also has support for YAML, JSON, TOML or Coffee Front-Matter, with options to set custom delimiters. See the benchmarks. gray-matter is 15-30x faster than front-matter.
gray-matter. Parse front-matter from a string or file. Fast, reliable and easy to use. Parses YAML front matter by default, but also has support for YAML, JSON, TOML or Coffee Front-Matter, with options to set custom delimiters. Used by metalsmith, assemble, verb and many other projects.
api documentation for gray-matter (v2.1.1) Parse front-matter from a string or file. Fast, reliable and easy to use. Parses YAML front matter by default, but also has support for YAML, JSON, TOML or Coffee Front-Matter, with options to set custom delimiters. Used by metalsmith, assemble, verb and
30 cze 2023 · 1. After migrating an app from Next 12 to Next 13, I found that gray-matter broke down. The same code worked fine, in the previous version of Next.js, i.e., Next 12. Prior to migration, the following code worked fine: const source = fs.readFileSync(sourcePath); const {content, data} = matter(source); It returned the desired result.
Parse front-matter from a string or file. Fast, reliable and easy to use. Parses YAML front matter by default, but also has support for YAML, JSON, TOML or Coffee Front-Matter, with options to set custom delimiters. Used by metalsmith, assemble, verb and .
Instead of defining the language on the options, gray-matter will automatically detect the language defined after the first delimiter and select the correct engine to use for parsing. 440 441