deckardcain
Advanced tools
Comparing version 0.3.4 to 0.3.5
@@ -9,9 +9,11 @@ 'use strict'; | ||
exports.API_BLUEPRINT_HEADER = API_BLUEPRINT_HEADER; | ||
var API_BLUEPRINT_RESPONSE = /\+\s+(?:response|request)\s+\d{3}/i; | ||
var API_BLUEPRINT_LISTITEM = /[-\*\+]\s+(response|request|attributes?)/i; | ||
exports.API_BLUEPRINT_LISTITEM = API_BLUEPRINT_LISTITEM; | ||
var API_BLUEPRINT_DATA = /#+\s+data structures?\s*\n/i; | ||
exports.API_BLUEPRINT_RESPONSE = API_BLUEPRINT_RESPONSE; | ||
exports.API_BLUEPRINT_DATA = API_BLUEPRINT_DATA; | ||
var LEGACY_BLUEPRINT_TITLE = /[-]{3}(?=( [^\n\r]+ | )[-]{3}([\n\r]{1,2}|[.]{0}))/i; | ||
exports.LEGACY_BLUEPRINT_TITLE = LEGACY_BLUEPRINT_TITLE; | ||
var SWAGGER_JSON = /^[\uFEFF]?{[\s\S]*["']swagger["']: ?["']\d\.\d["'],?/i; | ||
var SWAGGER_JSON = /^[\uFEFF]?{[\s\S]*["']swagger["']\s*:\s*["']\d\.\d["'],?/i; | ||
exports.SWAGGER_JSON = SWAGGER_JSON; | ||
@@ -21,7 +23,7 @@ var SWAGGER_YAML = /(?:^|\n)\s*swagger: ["']\d\.\d["']\n/i; | ||
exports.SWAGGER_YAML = SWAGGER_YAML; | ||
var REFRACT_API_DESCRIPTION_ELEMENT_JSON = /[\uFEFF]?\n?\s*["']element["']: ?["']category["']/i; | ||
var REFRACT_API_DESCRIPTION_ELEMENT_JSON = /[\uFEFF]?\n?\s*["']element["']\s*:\s*["']category["']/i; | ||
exports.REFRACT_API_DESCRIPTION_ELEMENT_JSON = REFRACT_API_DESCRIPTION_ELEMENT_JSON; | ||
var REFRACT_API_DESCRIPTION_CLASS_JSON = /"meta"\s*:\s*\{\s*"classes"\:\s*\[\s*"api"\s*\]/i; | ||
var REFRACT_API_DESCRIPTION_CLASS_JSON = /"meta"\s*:\s*\{\s*"classes"\s*:\s*\[\s*"api"\s*\]/i; | ||
exports.REFRACT_API_DESCRIPTION_CLASS_JSON = REFRACT_API_DESCRIPTION_CLASS_JSON; | ||
var REFRACT_PARSE_RESULT_ELEMENT_JSON = /[\uFEFF]?\n?\s*["']element["']: ?["']parseResult["']/i; | ||
var REFRACT_PARSE_RESULT_ELEMENT_JSON = /[\uFEFF]?\n?\s*["']element["']\s*:\s*["']parseResult["']/i; | ||
@@ -76,3 +78,3 @@ exports.REFRACT_PARSE_RESULT_ELEMENT_JSON = REFRACT_PARSE_RESULT_ELEMENT_JSON; | ||
if (source.match(API_BLUEPRINT_RESPONSE)) { | ||
if (source.match(API_BLUEPRINT_LISTITEM) || source.match(API_BLUEPRINT_DATA)) { | ||
// Didn't find '--- Sample Title ---' and at the same time | ||
@@ -79,0 +81,0 @@ // there is something like '+ Response 200' in the document, which is |
{ | ||
"name": "deckardcain", | ||
"version": "0.3.4", | ||
"version": "0.3.5", | ||
"description": "Identifies (media) type of API description files", | ||
@@ -5,0 +5,0 @@ "main": "lib/deckardcain", |
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
8899
6
70