Socket
Socket
Sign inDemoInstall

gray-matter

Package Overview
Dependencies
13
Maintainers
2
Versions
55
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.2.2 to 1.2.3

test/parse-custom.js

15

.verb.md

@@ -55,2 +55,17 @@ # {%= name %} {%= badge("fury") %}

## options.parser
Type: `Function`
Default: `undefined`
Pass a custom parser on the options. This is useful if you need to, for example, define custom schemas for [js-yaml].
**Example**
```js
matter(str, {
parser: require('js-yaml').safeLoad
});
```
## options.eval

@@ -57,0 +72,0 @@ Type: `Boolean`

2

lib/parsers.js

@@ -40,3 +40,3 @@ /**

parser.yaml = function(str, options) {
var opts = extend({strict: false, saftLoad: false}, options);
var opts = extend({strict: false, safeLoad: false}, options);
try {

@@ -43,0 +43,0 @@ var YAML = parser.requires.yaml || (parser.requires.yaml = require('js-yaml'));

{
"name": "gray-matter",
"description": "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.",
"version": "1.2.2",
"version": "1.2.3",
"author": {

@@ -6,0 +6,0 @@ "name": "Jon Schlinkert",

@@ -112,2 +112,17 @@ # gray-matter [![NPM version](https://badge.fury.io/js/gray-matter.svg)](http://badge.fury.io/js/gray-matter)

## options.parser
Type: `Function`
Default: `undefined`
Pass a custom parser on the options. This is useful if you need to, for example, define custom schemas for [js-yaml].
**Example**
```js
matter(str, {
parser: require('js-yaml').safeLoad
});
```
## options.eval

@@ -288,3 +303,3 @@ Type: `Boolean`

_This file was generated by [verb](https://github.com/assemble/verb) on February 06, 2015._
_This file was generated by [verb](https://github.com/assemble/verb) on February 12, 2015._

@@ -291,0 +306,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc