standard / snazzy Goto Github PK
View Code? Open in Web Editor NEWFormat JavaScript Standard Style as Stylish (i.e. snazzy) output
Home Page: https://standardjs.com
License: MIT License
Format JavaScript Standard Style as Stylish (i.e. snazzy) output
Home Page: https://standardjs.com
License: MIT License
Any thoughts on having a good job
state for parsing standard output and seeing no linting errors?
Hey,
can you please update chalk to 2.* the stripColor
function has been removed, which breaks my build because I use chalk somewhere else as well. Thank you.
I've been all over the place with this issue, posting on standard, then ESLint, back to standard and now here 😆
If I have the code:
const onionoo = new Onionoo()
to create a new instance of the Onionoo
class but leave off the brackets:
const onionoo = new Onionoo
standard
and ESLint give the error Missing '()' invoking a constructor
but snazzy
just returns Missing '
:
$ standard
standard: Use JavaScript Standard Style (http://standardjs.com)
standard: Run `standard --fix` to automatically fix some problems.
/Users/lukechilds/Dev/oss/onionoo-node-client/test/unit.js:14:19: Missing '()' invoking a constructor.
$ snazzy
standard: Use JavaScript Standard Style (http://standardjs.com)
standard: Run `standard --fix` to automatically fix some problems.
/Users/lukechilds/Dev/oss/onionoo-node-client/test/unit.js
14:19 error Missing '
✖ 1 problem
Error: Failed to load plugin react: Cannot find module 'eslint-plugin-react'
at Function.Module._resolveFilename (module.js:326:15)
at Function.Module._load (module.js:277:25)
at Module.require (module.js:354:17)
at require (internal/module.js:12:17)
at Object.module.exports.load (/Users/iradchenko/sandbox/core/node_modules/eslint/lib/config/plugins.js:116:26)
at Array.forEach (native)
at Object.module.exports.loadAll (/Users/iradchenko/sandbox/core/node_modules/eslint/lib/config/plugins.js:134:21)
at processText (/Users/iradchenko/sandbox/core/node_modules/eslint/lib/cli-engine.js:158:17)
at processFile (/Users/iradchenko/sandbox/core/node_modules/eslint/lib/cli-engine.js:227:18)
at executeOnFile (/Users/iradchenko/sandbox/core/node_modules/eslint/lib/cli-engine.js:602:23)
Not sure why I'd need to install this, since I'm not using react. Seems like a dep is missing somewhere..
Apologies uprfront (I am a newbie). The newest version of snazzy (7.1.0) has caused a breaking change for me. I get the following error TypeError: chalk.stripColor is not a function. I have no troubles if I fall back to 7.0.0
This is probably more of an issue with solarized than snazzy, but with solarized-dark, the line numbers and other important information are the same colour as the background, so text needs to be highlighted to see what the information actually is.
I know its a very old version but a lot of legacy projects in production are using 0.8
. When they try to move to standard, their builds start to fail For example in node-config/node-config#307 the standard integration breaks the build — https://travis-ci.org/lorenwest/node-config/builds/121860743
Its I think because of the way inherits works for different versions of node.
Hey man, just wondering why this is a separate repo and not an update to standard. Seems like this is an improvement that every standard user would benefit from.
Do you know which package is in charge of building this json?
{
line: '2',
column: '17',
message: 'Expected property shorthand.',
ruleId: 'object-shorthand) (warning'
}
If this is not being created by Snazzy (as it appears to my eyes, I'm not a JavaScript developer), I think that there could be an issue somewhere else upstream that should be fixed before adding warning support to Snazzy
Originally posted by @tagliala in standard/eslint-config-standard#229 (comment)
snazzy
is supposed to support all of standard
's options, however--stdin
doesn't seem to work. If I echo in "fail" it should return 'fail' is not defined
.
$ echo fail | standard --stdin
standard: Use JavaScript Standard Style (http://standardjs.com)
<text>:1:1: 'fail' is not defined.
$ echo fail | snazzy --stdin
fail
What version of this package are you using?
What problem do you want to solve?
What do you think is the correct solution to this problem?
Are you willing to submit a pull request to implement this change?
I receive the following error when trying to run snazzy
by itself, it works fine to run it as standard --verbose | snazzy
but seems to have trouble spawning the child process.
internal/child_process.js:298
throw errnoException(err, 'spawn');
^
Error: spawn UNKNOWN
at exports._errnoException (util.js:814:11)
at ChildProcess.spawn (internal/child_process.js:298:11)
at Object.exports.spawn (child_process.js:333:9)
at Object.<anonymous> (C:\Program Files\iojs\node_modules\snazzy\bin\cmd.js:27:21)
at Module._compile (module.js:430:26)
at Object.Module._extensions..js (module.js:448:10)
at Module.load (module.js:355:32)
at Function.Module._load (module.js:310:12)
at Function.Module.runMain (module.js:471:10)
at startup (node.js:117:18)
What version of this package are you using?
The latest stable version.
What problem do you want to solve?
Not having to waste time digging in the commit history to see what changed.
What do you think is the correct solution to this problem?
Implementing the changelog with the help of a tool such as standard-version or conventional-changelog-writer
Are you willing to submit a pull request to implement this change?
Unfortunately not.
To reproduce add standard@beta
and snazzy
to a project. Afterward running standard (standalone or via snazzy) will cause the error Definition for rule 'standard/no-callback-literal' was not found
. Uninstalling snazzy or installing standard 9 fixes the issue.
I'm trying to run the linter on a pre-commit script, so I want NPM to halt if there's a lint error. For whatever reason, NPM halts when Standard encounters an error, but not when Snazzy does.
Standard exits with code 1, while Snazzy exits with 255.
Can Snazzy pass thru the same exit code(s) that Standard produces?
Using snazzy
to parse eslint
output does not seem to honor eslint
exit code:
$ eslint .
...
✖ 3 problems (3 errors, 0 warnings)
$ echo $?
1
$ eslint . | snazzy
...
✖ 3 problems (3 errors, 0 warnings)
$ echo $?
0
Using:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.