Socket
Socket
Sign inDemoInstall

@jsdoc/parse

Package Overview
Dependencies
64
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.3.6 to 0.3.7

3

lib/handlers.js

@@ -19,3 +19,2 @@ /*

import { Doclet } from '@jsdoc/doclet';
import { log } from '@jsdoc/util';
import escape from 'escape-string-regexp';

@@ -47,2 +46,3 @@

let flatComment;
let log;
let msg;

@@ -55,2 +55,3 @@

msg = `cannot create a doclet for the comment "${flatComment}": ${error.message}`;
log = deps.get('log');
log.error(msg);

@@ -57,0 +58,0 @@ doclet = new Doclet('', e, deps);

@@ -22,3 +22,2 @@ /*

import { Doclet, DocletStore } from '@jsdoc/doclet';
import { log } from '@jsdoc/util';
import _ from 'lodash';

@@ -77,5 +76,6 @@

this._docletStore = new DocletStore(dependencies);
this._eventBus = dependencies.get('eventBus');
this._emitter = dependencies.get('emitter');
this._log = dependencies.get('log');
this._visitor = new Visitor();
this._walker = new Walker();
this._walker = new Walker(dependencies);

@@ -112,6 +112,6 @@ this._visitor.setParser(this);

// TODO: Always emit events from the event bus, never from the parser.
// TODO: Always emit events from the dependencies' emitter, never from the parser.
emit(eventName, event, ...args) {
super.emit(eventName, event, ...args);
this._eventBus.emit(eventName, event, ...args);
this._emitter.emit(eventName, event, ...args);
}

@@ -151,3 +151,3 @@

e.sourcefiles = sourceFiles;
log.debug('Parsing source files: %j', sourceFiles);
this._log.debug('Parsing source files: %j', sourceFiles);

@@ -168,3 +168,3 @@ this.emit('parseBegin', e);

} catch (err) {
log.error(`Unable to read and parse the source file ${filename}: ${err}`);
this._log.error(`Unable to read and parse the source file ${filename}: ${err}`);
}

@@ -185,3 +185,3 @@ }

}
log.debug('Finished parsing source files.');
this._log.debug('Finished parsing source files.');

@@ -218,2 +218,3 @@ return this._docletStore;

let ast;
const builder = new AstBuilder(this._dependencies);
let e = {

@@ -225,3 +226,3 @@ filename: sourceName,

this.emit('fileBegin', e);
log.info(`Parsing ${sourceName} ...`);
this._log.info(`Parsing ${sourceName} ...`);

@@ -240,3 +241,3 @@ if (!e.defaultPrevented) {

ast = AstBuilder.build(sourceCode, sourceName, sourceType);
ast = builder.build(sourceCode, sourceName, sourceType);
if (ast) {

@@ -243,0 +244,0 @@ this._walkAst(ast, this._visitor, sourceName);

{
"name": "@jsdoc/parse",
"version": "0.3.6",
"version": "0.3.7",
"description": "Parses, and extracts information from, source code.",

@@ -16,6 +16,6 @@ "keywords": [

"dependencies": {
"@jsdoc/ast": "^0.2.6",
"@jsdoc/ast": "^0.2.7",
"@jsdoc/core": "^0.5.5",
"@jsdoc/doclet": "^0.2.6",
"@jsdoc/util": "^0.3.1",
"@jsdoc/doclet": "^0.2.7",
"@jsdoc/util": "^0.3.2",
"escape-string-regexp": "^5.0.0"

@@ -42,3 +42,3 @@ },

},
"gitHead": "3fddc126ab49149c425d59abf6dde0289dd4eac3"
"gitHead": "a894b4f849d43bab0b5a2dfe35f07d0a3ccddba8"
}
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