This diff adds a web/ directory at the project root and a new linter
running prettier on all the Javascript files from this directory.
Details
- Reviewers
deadalnix bytesofman - Group Reviewers
Restricted Project - Commits
- rABC7577f721476c: Add a prettier linter for the web tools
Follow the installation instructions from CONTRIBUTING.md.
Add a web/dummy.js file to the source tree with some Javascript
content, then:
arc lint --trace
Check the prettier linter is run.
Edit the web/.prettierrc file to set the tab width to 4.
arc lint
Check the web/dummy.js file is updated accordingly.
Diff Detail
- Repository
- rABC Bitcoin ABC
- Branch
- linter_prettier
- Lint
Lint Passed - Unit
No Test Coverage - Build Status
Buildable 14151 Build 28295: Build Diff lint-circular-dependencies · build-without-wallet · build-diff · build-clang · build-clang-tidy · build-debug Build 28294: arc lint + arc unit
Event Timeline
.arclint | ||
---|---|---|
278 ↗ | (On Diff #25904) | It's nto just js, css, scss and so on are good candidates. |
.gitignore | ||
86 ↗ | (On Diff #25904) | |
web/.prettierrc | ||
2 ↗ | (On Diff #25904) | The rest of the codebase use 80 |
4 ↗ | (On Diff #25904) | We use 4 in the rest of the codebase. |
7 ↗ | (On Diff #25904) | quoteProps: consistent |
Back to your plate, this clearly hasn't been thought through.
.arclint | ||
---|---|---|
279 | I don't think this really make any sense. |
CONTRIBUTING.md | ||
---|---|---|
180 ↗ | (On Diff #25962) | npm is included with nodejs. For web development with node, nvm is an important tool. I think lines 171-180 should read: Contributing to web projects If you intend to contribute to web projects, you will need nodejs. Follow the installation instructions here to install node with node version manager. Then, cd bitcoin-abc npm i -g prettier |
Looks good to me. We may see additional needs here as more web repositories are added, but I think this is an appropriate starting point.