gray-matter

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 (by jonschlinkert)

Gray-matter Alternatives

Similar projects and alternatives to gray-matter

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a better gray-matter alternative or higher similarity.

gray-matter reviews and mentions

Posts with mentions or reviews of gray-matter. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-04-21.
  • Create an Interactive Table of Contents for a Next.js Blog with Remark
    5 projects | dev.to | 21 Apr 2023
    Although we are building a custom table of contents, we won't have to write everything from scratch. To separate the Markdown/MDX content from the front matter, we'll use the Gray-matter package. It is optional in case you don't have front matter in your Markdown files. To process the Markdown itself, we'll use the Remark package. We'll also need the unist-util-visit package for traversing node trees and mdast-util-to-string for getting the text content of a node.
  • Create your own blog with MDX and NextJS
    2 projects | dev.to | 5 Dec 2022
    In this article we walk you through the process of creating a simple blog app using the popular React framework NextJS, gray-matter and next-mdx-remote.
  • NextJS 13 Blog Starter
    6 projects | dev.to | 14 Nov 2022
    In order to get post information (such as author, title, date, etc.) from our HTML without having them be apart of our rendered post we need a way to parse YAML front matter, this is where gray-matter comes in hand.
  • Create a Markdown Editor with Rust and React
    12 projects | dev.to | 13 Oct 2022
    It’s actually not part of the CommonMark spec, so you’ll often need a 3rd party library to parse it out on top of your Markdown parser. In JavaScript we use gray-matter which converts frontmatter into a JS object we can more easily use.
  • Turn a Markdown blog to a simple SSG
    4 projects | dev.to | 30 Jul 2022
    Over the past few weeks, I mostly wrote on how to template a Node.js application with EJS using Express. Then, I wrote an article showing how to create a Markdown blog in Node.js using EJS, Express, gray-matter and markdown-it. Today, I'll combine those tutorials to turn the Markdown blog, from the last tutorial, into a simple SSG.
  • Markdown blog with EJS
    3 projects | dev.to | 25 Jul 2022
    gray-matter, to parse the front matter from the Markdown files
  • Create Blog Post Bookmarks in Next.js
    3 projects | dev.to | 6 Jun 2022
    Luckily for us, there is a fantastic NPM package that can help us with this. Let’s install it.
  • How I built my portfolio using NextJS, Typescript, and Chakra UI
    10 projects | dev.to | 24 Oct 2021
    gray-matter: Converts a string with front-matter to object.
  • How to create a blog for your Next.js and ChakraUI website
    4 projects | dev.to | 31 Jul 2021
    Load the frontmatter - gray-matter
  • How I Built An Incomplete CMS
    4 projects | dev.to | 23 Jun 2021
    I began building a blog application for a site that I may or may not finish. The bulk of the project is based on the blog-starter-typescript example in the NextJs GitHub repo. Their example loads markdown files from a folder in the root directory and uses remark and gray-matter to convert the markdown into html and to get file metadata. The example code for these function is located in their lib folder as api.ts and markdownToHtml.ts.
  • A note from our sponsor - Amplication
    amplication.com | 21 Sep 2023
    An open-source platform that helps developers build backends without spending time on boilerplate & repetitive coding. Including production-ready GraphQL & REST APIs, DB schema, DTOs, filtering, pagination, RBAC, & more. Learn more →

Stats

Basic gray-matter repo stats
14
3,452
0.0
2 months ago
Write Clean JavaScript Code. Always.
Sonar helps you commit clean code every time. With over 300 unique rules to find JavaScript bugs, code smells & vulnerabilities, Sonar finds the issues while you focus on the work.
www.sonarsource.com