Comparing version 0.1.0 to 0.1.1
{ | ||
"name": "jsd-jekyll", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"description": "JSDoc Plugin and Template for making a Github Pages compatable Jekyll Site", | ||
"main": "src/index.js", | ||
"main": "src/main.js", | ||
"scripts": {}, | ||
@@ -14,3 +14,2 @@ "repository": { | ||
"dependencies": { | ||
"esm": "^3.2.25", | ||
"fs-extra": "^9.0.1", | ||
@@ -17,0 +16,0 @@ "js-yaml": "^3.14.1" |
/** | ||
* JSDoc plugin | ||
*/ | ||
import { processParams, processTypes, githubUrl, extract } from "./processing"; | ||
import fs from "fs"; | ||
import env from "jsdoc/lib/jsdoc/env"; | ||
const { processParams, processTypes, githubUrl, extract } = require("./processing"); | ||
const fs = require("jsdoc/fs"); | ||
const env = require("jsdoc/env"); | ||
exports.handlers = { | ||
// parseBegin: function(e) { | ||
// console.log("START: ParseBegin function (only used for testing)"); | ||
// console.log("END: ParseBegin function (only used for testing)"); | ||
// }, | ||
newDoclet: function(e) { | ||
@@ -42,3 +38,2 @@ if (e.doclet.hasOwnProperty("params")) { | ||
) { | ||
count++; | ||
e.doclet.meta.url = githubUrl(e.doclet.meta, env.opts.repos); | ||
@@ -49,6 +44,2 @@ let regex = new RegExp(env.opts.repos[0]["folder"] + "(.*)"); | ||
}, | ||
parseComplete: function(e) { | ||
// console.log("START: ParseComplete function (only used for testing)"); | ||
// console.log("END: ParseComplete function (only used for testing)"); | ||
} | ||
}; | ||
@@ -104,8 +95,2 @@ | ||
}); | ||
// dictionary.defineTag("authentication", { | ||
// mustHaveValue: true, | ||
// onTagged: (doclet, tag) => { | ||
// doclet.routeParam = tag.value; | ||
// } | ||
// }); | ||
}; | ||
@@ -118,3 +103,3 @@ | ||
* @param {type} tag the jsdoc tag object | ||
* @param {type} key Name of the property of the doclet to save the tag.value to | ||
* @param {type} key Name of the property of the doclet to save the tag.value to | ||
*/ | ||
@@ -121,0 +106,0 @@ function paramOnTagged(doclet, tag, key) { |
@@ -11,3 +11,3 @@ /** | ||
*/ | ||
export function processParams(input) { | ||
function processParams(input) { | ||
var paramStrings = []; | ||
@@ -45,3 +45,3 @@ var params = []; | ||
*/ | ||
export function processTypes(names) { | ||
function processTypes(names) { | ||
names.forEach((name, i) => { | ||
@@ -92,3 +92,3 @@ let isArray = false; | ||
*/ | ||
export function githubUrl(meta, repos) { | ||
function githubUrl(meta, repos) { | ||
var url = ""; | ||
@@ -104,7 +104,2 @@ //For subrepositories will try to match each repoUrl, so that the nested repo url will be returned. | ||
: url; | ||
// repo.url + | ||
// extract(meta.path, regex) + | ||
// meta.filename + | ||
// "#L" + | ||
// meta.lineno | ||
}); | ||
@@ -120,4 +115,6 @@ return url; | ||
*/ | ||
export function extract(string, regex) { | ||
function extract(string, regex) { | ||
return string.match(regex)[1]; | ||
} | ||
module.exports = { processParams, processTypes, githubUrl, extract }; |
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
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
3
1
30288
26
359
- Removedesm@^3.2.25
- Removedesm@3.2.25(transitive)