Comparing version 0.0.0-alpha.4 to 0.9.0-RC
{ | ||
"name": "svglint", | ||
"version": "0.0.0-alpha.4", | ||
"description": "svglinter for js applications", | ||
"main": "lib/svglint.js", | ||
"files": [ | ||
"lib/", | ||
"bin/" | ||
], | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/fenderil/svglint.git" | ||
}, | ||
"version": "0.9.0-RC", | ||
"description": "Linter for SVGs", | ||
"main": "src/svglint.js", | ||
"bin": { "svglint": "./bin/cli.js" }, | ||
"keywords": [ | ||
"svg", | ||
"svglint", | ||
"svglint-config", | ||
"svglint-plugin" | ||
"vector", | ||
"lint", | ||
"linting", | ||
"linter" | ||
], | ||
"license": "MIT", | ||
"bugs": { | ||
"url": "https://github.com/fenderil/svglint/issues" | ||
"author": "birjolaxew", | ||
"license": "CC0", | ||
"scripts": { | ||
"lint": "eslint src/**/*.js test/**/*.js", | ||
"test": "mocha" | ||
}, | ||
"homepage": "https://github.com/fenderil/svglint#readme", | ||
"dependencies": { | ||
"chalk": "^2.3.0", | ||
"commander": "^2.13.0", | ||
"glob": "^7.1.2", | ||
"jsdom": "^11.5.1", | ||
"lodash": "^4.17.4" | ||
"ansi-regex": "^3.0.0", | ||
"chalk": "^2.4.1", | ||
"cheerio": "^1.0.0-rc.2", | ||
"htmlparser2": "^3.9.1", | ||
"log-update": "^2.3.0", | ||
"meow": "^3.7.0", | ||
"strip-ansi": "^4.0.0" | ||
}, | ||
"author": { | ||
"name": "Tupitckiy Ilya", | ||
"email": "fenderil@yandex.ru", | ||
"url": "https://github.com/fenderil" | ||
}, | ||
"bin": { | ||
"svglint": "./bin/svglint.js" | ||
}, | ||
"engines": { | ||
"node": ">=6.1.0" | ||
"devDependencies": { | ||
"eslint": "^4.19.1", | ||
"expect": "^1.20.2", | ||
"mocha": "^5.2.0" | ||
} | ||
} |
@@ -1,10 +0,68 @@ | ||
# svglint | ||
svglinter for js applications | ||
# SVGLint | ||
TODOs: | ||
* svglint.config - different file types | ||
* svglint.config - extends config | ||
* svglint.config - extends plugin | ||
* --fix | ||
* ... | ||
* many else | ||
Lints SVG files. Can be run as a commandline utility, or as a NodeJS library. | ||
<p align="center"><img src="/example.png" alt="Example of a commandline execution"/></p> | ||
## Usage | ||
The tool can be used as a commandline tool by executing the CLI. | ||
If installed as a dependency by NPM this will be found at `./node_modules/.bin/svglint`. | ||
If installed globally by NPM it can be executed directly as `svglint`. | ||
``` | ||
$ svglint --help | ||
Linter for SVGs | ||
Usage: | ||
svglint [--config config.js] [--ci] [--debug] file1.svg file2.svg | ||
Options: | ||
--help Display this help text | ||
--version Show the current SVGLint version | ||
--config, -c Specify the config file. Defaults to '.svglintrc.js' | ||
--debug, -d Show debug logs | ||
--ci, -C Only output to stdout once, when linting is finished | ||
``` | ||
The tool can also be used through the JS API. | ||
```javascript | ||
const SVGLint = require("svglint"); | ||
SVGLint.lintSource("<svg>...</svg>", { | ||
// ... config goes here | ||
}); | ||
``` | ||
## Config | ||
In order to specify what should be linted SVGLint must be given a configuration object. | ||
If you are using the CLI, this configuration object is read from the file specified by `--config`. This defaults to `.svglintrc.js`, which will be searched for up through the directory tree - this is similar to tools such as ESLint. | ||
This configuration file should export a single object, of the format: | ||
```javascript | ||
module.exports = { | ||
// additional configuration may go here in the future | ||
// for now, "rules" is the only useful key | ||
rules: { | ||
elm: [{ | ||
// config 1 for the "elm" rule | ||
}, { | ||
// config 2 for the "elm" rule | ||
}], | ||
attr: { | ||
// config 1 for the "attr" rule | ||
}, | ||
custom: [ | ||
function() { // config 1 for the "custom" rule } | ||
] | ||
} | ||
}; | ||
``` | ||
For specifics on how the config for each rule should be formatted, see [their specific rule files](/src/rules/). | ||
If you are using the JS API, this configuration object is passed as the second parameter. | ||
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Misc. License Issues
License(Experimental) A package's licensing information has fine-grained problems.
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
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
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
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 3 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
107891
36
2181
2
69
5
7
3
1
2
+ Addedansi-regex@^3.0.0
+ Addedcheerio@^1.0.0-rc.2
+ Addedhtmlparser2@^3.9.1
+ Addedlog-update@^2.3.0
+ Addedmeow@^3.7.0
+ Addedstrip-ansi@^4.0.0
+ Addedansi-escapes@3.2.0(transitive)
+ Addedansi-regex@3.0.1(transitive)
+ Addedarray-find-index@1.0.2(transitive)
+ Addedboolbase@1.0.0(transitive)
+ Addedcamelcase@2.1.1(transitive)
+ Addedcamelcase-keys@2.1.0(transitive)
+ Addedcheerio@1.0.0(transitive)
+ Addedcheerio-select@2.1.0(transitive)
+ Addedcli-cursor@2.1.0(transitive)
+ Addedcss-select@5.1.0(transitive)
+ Addedcss-what@6.1.0(transitive)
+ Addedcurrently-unhandled@0.4.1(transitive)
+ Addeddecamelize@1.2.0(transitive)
+ Addeddom-serializer@0.2.22.0.0(transitive)
+ Addeddomelementtype@1.3.12.3.0(transitive)
+ Addeddomhandler@2.4.25.0.3(transitive)
+ Addeddomutils@1.7.03.2.2(transitive)
+ Addedencoding-sniffer@0.2.0(transitive)
+ Addedentities@1.1.22.2.04.5.0(transitive)
+ Addederror-ex@1.3.2(transitive)
+ Addedfind-up@1.1.2(transitive)
+ Addedfunction-bind@1.1.2(transitive)
+ Addedget-stdin@4.0.1(transitive)
+ Addedgraceful-fs@4.2.11(transitive)
+ Addedhasown@2.0.2(transitive)
+ Addedhosted-git-info@2.8.9(transitive)
+ Addedhtmlparser2@3.10.19.1.0(transitive)
+ Addediconv-lite@0.6.3(transitive)
+ Addedindent-string@2.1.0(transitive)
+ Addedis-arrayish@0.2.1(transitive)
+ Addedis-core-module@2.16.1(transitive)
+ Addedis-finite@1.1.0(transitive)
+ Addedis-fullwidth-code-point@2.0.0(transitive)
+ Addedis-utf8@0.2.1(transitive)
+ Addedload-json-file@1.1.0(transitive)
+ Addedlog-update@2.3.0(transitive)
+ Addedloud-rejection@1.6.0(transitive)
+ Addedmap-obj@1.0.1(transitive)
+ Addedmeow@3.7.0(transitive)
+ Addedmimic-fn@1.2.0(transitive)
+ Addedminimist@1.2.8(transitive)
+ Addednormalize-package-data@2.5.0(transitive)
+ Addednth-check@2.1.1(transitive)
+ Addedobject-assign@4.1.1(transitive)
+ Addedonetime@2.0.1(transitive)
+ Addedparse-json@2.2.0(transitive)
+ Addedparse5@7.2.1(transitive)
+ Addedparse5-htmlparser2-tree-adapter@7.1.0(transitive)
+ Addedparse5-parser-stream@7.1.2(transitive)
+ Addedpath-exists@2.1.0(transitive)
+ Addedpath-parse@1.0.7(transitive)
+ Addedpath-type@1.1.0(transitive)
+ Addedpify@2.3.0(transitive)
+ Addedpinkie@2.0.4(transitive)
+ Addedpinkie-promise@2.0.1(transitive)
+ Addedread-pkg@1.1.0(transitive)
+ Addedread-pkg-up@1.0.1(transitive)
+ Addedreadable-stream@3.6.2(transitive)
+ Addedredent@1.0.0(transitive)
+ Addedrepeating@2.0.1(transitive)
+ Addedresolve@1.22.10(transitive)
+ Addedrestore-cursor@2.0.0(transitive)
+ Addedsemver@5.7.2(transitive)
+ Addedsignal-exit@3.0.7(transitive)
+ Addedspdx-correct@3.2.0(transitive)
+ Addedspdx-exceptions@2.5.0(transitive)
+ Addedspdx-expression-parse@3.0.1(transitive)
+ Addedspdx-license-ids@3.0.21(transitive)
+ Addedstring-width@2.1.1(transitive)
+ Addedstring_decoder@1.3.0(transitive)
+ Addedstrip-ansi@4.0.0(transitive)
+ Addedstrip-bom@2.0.0(transitive)
+ Addedstrip-indent@1.0.1(transitive)
+ Addedsupports-preserve-symlinks-flag@1.0.0(transitive)
+ Addedtrim-newlines@1.0.0(transitive)
+ Addedundici@6.21.1(transitive)
+ Addedutil-deprecate@1.0.2(transitive)
+ Addedvalidate-npm-package-license@3.0.4(transitive)
+ Addedwhatwg-encoding@3.1.1(transitive)
+ Addedwhatwg-mimetype@4.0.0(transitive)
+ Addedwrap-ansi@3.0.1(transitive)
- Removedcommander@^2.13.0
- Removedglob@^7.1.2
- Removedjsdom@^11.5.1
- Removedlodash@^4.17.4
- Removedabab@2.0.6(transitive)
- Removedacorn@5.7.46.4.2(transitive)
- Removedacorn-globals@4.3.4(transitive)
- Removedacorn-walk@6.2.0(transitive)
- Removedajv@6.12.6(transitive)
- Removedarray-equal@1.0.2(transitive)
- Removedasn1@0.2.6(transitive)
- Removedassert-plus@1.0.0(transitive)
- Removedasync-limiter@1.0.1(transitive)
- Removedasynckit@0.4.0(transitive)
- Removedaws-sign2@0.7.0(transitive)
- Removedaws4@1.13.2(transitive)
- Removedbalanced-match@1.0.2(transitive)
- Removedbcrypt-pbkdf@1.0.2(transitive)
- Removedbrace-expansion@1.1.11(transitive)
- Removedbrowser-process-hrtime@1.0.0(transitive)
- Removedcaseless@0.12.0(transitive)
- Removedcombined-stream@1.0.8(transitive)
- Removedcommander@2.20.3(transitive)
- Removedconcat-map@0.0.1(transitive)
- Removedcore-util-is@1.0.2(transitive)
- Removedcssom@0.3.8(transitive)
- Removedcssstyle@1.4.0(transitive)
- Removeddashdash@1.14.1(transitive)
- Removeddata-urls@1.1.0(transitive)
- Removeddeep-is@0.1.4(transitive)
- Removeddelayed-stream@1.0.0(transitive)
- Removeddomexception@1.0.1(transitive)
- Removedecc-jsbn@0.1.2(transitive)
- Removedescodegen@1.14.3(transitive)
- Removedesprima@4.0.1(transitive)
- Removedestraverse@4.3.0(transitive)
- Removedesutils@2.0.3(transitive)
- Removedextend@3.0.2(transitive)
- Removedextsprintf@1.3.0(transitive)
- Removedfast-deep-equal@3.1.3(transitive)
- Removedfast-json-stable-stringify@2.1.0(transitive)
- Removedfast-levenshtein@2.0.6(transitive)
- Removedforever-agent@0.6.1(transitive)
- Removedform-data@2.3.3(transitive)
- Removedfs.realpath@1.0.0(transitive)
- Removedgetpass@0.1.7(transitive)
- Removedglob@7.2.3(transitive)
- Removedhar-schema@2.0.0(transitive)
- Removedhar-validator@5.1.5(transitive)
- Removedhtml-encoding-sniffer@1.0.2(transitive)
- Removedhttp-signature@1.2.0(transitive)
- Removediconv-lite@0.4.24(transitive)
- Removedinflight@1.0.6(transitive)
- Removedis-typedarray@1.0.0(transitive)
- Removedisstream@0.1.2(transitive)
- Removedjsbn@0.1.1(transitive)
- Removedjsdom@11.12.0(transitive)
- Removedjson-schema@0.4.0(transitive)
- Removedjson-schema-traverse@0.4.1(transitive)
- Removedjson-stringify-safe@5.0.1(transitive)
- Removedjsprim@1.4.2(transitive)
- Removedleft-pad@1.3.0(transitive)
- Removedlevn@0.3.0(transitive)
- Removedlodash@4.17.21(transitive)
- Removedlodash.sortby@4.7.0(transitive)
- Removedmime-db@1.52.0(transitive)
- Removedmime-types@2.1.35(transitive)
- Removedminimatch@3.1.2(transitive)
- Removednwsapi@2.2.16(transitive)
- Removedoauth-sign@0.9.0(transitive)
- Removedonce@1.4.0(transitive)
- Removedoptionator@0.8.3(transitive)
- Removedparse5@4.0.0(transitive)
- Removedpath-is-absolute@1.0.1(transitive)
- Removedperformance-now@2.1.0(transitive)
- Removedpn@1.1.0(transitive)
- Removedprelude-ls@1.1.2(transitive)
- Removedpsl@1.15.0(transitive)
- Removedpunycode@2.3.1(transitive)
- Removedqs@6.5.3(transitive)
- Removedrequest@2.88.2(transitive)
- Removedrequest-promise-core@1.1.4(transitive)
- Removedrequest-promise-native@1.0.9(transitive)
- Removedsax@1.4.1(transitive)
- Removedsource-map@0.6.1(transitive)
- Removedsshpk@1.18.0(transitive)
- Removedstealthy-require@1.1.1(transitive)
- Removedsymbol-tree@3.2.4(transitive)
- Removedtough-cookie@2.5.0(transitive)
- Removedtr46@1.0.1(transitive)
- Removedtunnel-agent@0.6.0(transitive)
- Removedtweetnacl@0.14.5(transitive)
- Removedtype-check@0.3.2(transitive)
- Removeduri-js@4.4.1(transitive)
- Removeduuid@3.4.0(transitive)
- Removedverror@1.10.0(transitive)
- Removedw3c-hr-time@1.0.2(transitive)
- Removedwebidl-conversions@4.0.2(transitive)
- Removedwhatwg-encoding@1.0.5(transitive)
- Removedwhatwg-mimetype@2.3.0(transitive)
- Removedwhatwg-url@6.5.07.1.0(transitive)
- Removedword-wrap@1.2.5(transitive)
- Removedwrappy@1.0.2(transitive)
- Removedws@5.2.4(transitive)
- Removedxml-name-validator@3.0.0(transitive)
Updatedchalk@^2.4.1