- Linting:

- npm: Update eslint-plugin-jsdoc
master
Brett Zamir 2019-05-24 16:35:15 +08:00
parent d88e542dad
commit f6b5360a58
4 changed files with 10 additions and 9 deletions

View File

@ -65,8 +65,9 @@ module.exports = {
}
}
*/
// Todo: Remove after ash-nazg update
forceRequireReturn: true,
// Todo: Once PR to eslint-plugin-jsdoc may be merged, fix its "reenable later" to-dos for `jsdoc/check-types` in canvg.js file
// Todo: Remove if ash-nazg has sufficiently merged
preferredTypes: {
"*": {
message: "Use a more precise type or if necessary use `{{preferredType}}` or `ArbitraryCallbackResult`",
@ -83,11 +84,11 @@ module.exports = {
message: "Point to a `@callback` namepath or `{{preferredType}}` if truly arbitrary in form",
replacement: "GenericCallback"
},
'object<>': {
object: {
message: "Use the specific object type or `{{preferredType}}` (or `ArbitraryObject` or `ArbitraryModule`) if truly arbitrary",
replacement: "PlainObject"
},
'Array<>': {
Array: {
message: "Use `{{preferredType}}` (or `ArgumentsArray`) if it is truly arbitrary.",
replacement: "GenericArray"
}

View File

@ -90,14 +90,14 @@ export const canvg = function (target, s, opts) {
return svg.load(ctx, s);
};
/* Todo: Reenable after ash-nazg may merge; eslint-disable jsdoc/check-types */
/* eslint-disable jsdoc/check-types */
/**
* @param {module:canvg.CanvgOptions} opts
* @returns {object}
* @todo Flesh out exactly what object is returned here (after updating to latest and reincluding our changes here and those of StackBlur)
*/
function build (opts) {
/* Todo: Reenable after ash-nazg may merge; eslint-enable jsdoc/check-types */
/* eslint-enable jsdoc/check-types */
const svg = {opts};
svg.FRAMERATE = 30;

6
package-lock.json generated
View File

@ -4178,9 +4178,9 @@
}
},
"eslint-plugin-jsdoc": {
"version": "6.0.3",
"resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-6.0.3.tgz",
"integrity": "sha512-J5aHmFxxWi/82xcmnJLjfcwiJR1uu13jK4AhRFY0KoK0ItcuPoKesvW6O4gjgdIn82Y5Bd4enWTkiop/wslDcw==",
"version": "7.0.0",
"resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-7.0.0.tgz",
"integrity": "sha512-Yu9nfWDG5zJWK1l65MYu7GjHPltPdhZz8m6oqD/h2jDxNgSltgqH5irR5kS38F3eTb4zhS7+FaHE8bz1ph7omQ==",
"dev": true,
"requires": {
"comment-parser": "^0.5.4",

View File

@ -91,7 +91,7 @@
"eslint-plugin-compat": "^3.1.1",
"eslint-plugin-eslint-comments": "^3.1.1",
"eslint-plugin-import": "2.17.2",
"eslint-plugin-jsdoc": "^6.0.3",
"eslint-plugin-jsdoc": "^7.0.0",
"eslint-plugin-markdown": "^1.0.0",
"eslint-plugin-no-use-extend-native": "^0.4.0",
"eslint-plugin-node": "9.1.0",