front-matter
Advanced tools
Comparing version 0.1.0 to 0.1.1
24
index.js
@@ -17,11 +17,21 @@ var parser = require('yaml-js') | ||
function matcher(string, seperator){ | ||
var seperator = seperator || '---' | ||
, pattern = '^(' | ||
+ seperator | ||
+ '$([\\s\\S]*?)' | ||
+ seperator+'$\\n)' | ||
, regex = new RegExp(pattern, 'm') | ||
, match = regex.exec(string) | ||
if (process.platform === 'win32') | ||
var seperator = seperator || '---' | ||
, pattern = '^(' | ||
+ seperator | ||
+ '$([\\s\\S]*?)' | ||
+ seperator+'$\\r\\n)' | ||
, regex = new RegExp(pattern, 'm') | ||
, match = regex.exec(string) | ||
else | ||
var seperator = seperator || '---' | ||
, pattern = '^(' | ||
+ seperator | ||
+ '$([\\s\\S]*?)' | ||
+ seperator+'$\\n)' | ||
, regex = new RegExp(pattern, 'm') | ||
, match = regex.exec(string) | ||
if (match && match.length > 0) return match | ||
} |
@@ -7,3 +7,3 @@ { | ||
"license": "MIT", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"homepage": "https://github.com/jxson/front-matter", | ||
@@ -10,0 +10,0 @@ "bugs": "https://github.com/jxson/front-matter/issues", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8631
121