Page MenuHomePhabricator

Adding a npm fix script to ProofreadPage extension
Closed, ResolvedPublic

Description

composer has a handy script, composer fix that allows one to write code in php and then wipe out the minor linting errors such as whitespaces mismatches. This saves quite a lot of time which would otherwise be spent searching for line and column numbers :)

Npm, on the other hand, doesn't have such a script. It becomes very tedious going after each and every line number and fixing every whitespace error especially when the size of the files being committed are quite big.

We should add a npm fix script that should fix the automatically fixable warnings generated by eslint and stylelint during npm test.

Event Timeline

Change 606806 had a related patch set uploaded (by Sohom Datta; owner: Sohom Datta):
[mediawiki/extensions/ProofreadPage@master] Add a npm 'fix' script

https://gerrit.wikimedia.org/r/606806

Change 606806 merged by jenkins-bot:
[mediawiki/extensions/ProofreadPage@master] Add a npm 'fix' script

https://gerrit.wikimedia.org/r/606806

@Soda is this done?

Yeah, this is done :) (fixing linting errors manually is hands-down the most tedious part of writing JS code)