decentraland / decentraland/sdk
Create `lint` command
- Dominant language
- No language data
- Stars
- 4
- Forks
- 5
- PR merge metrics
- No merged PRs in 30d
Description
Depends on https://github.com/decentraland/sdk/issues/503
Create a linter command that is installed along with the `@dcl/sdk` it should detect that no side effects are executed at root level of the imported files and it should warn about empty imports like `import "./file"` because those are going to be tree shaken.
It also must detect floating promises and fail if those are found.
The `lint` implementation may live inside `dcl-rollup` repository since it is a crucial part of the building process to raise problems as part of the static checks.
The `lint` command should also be accessible via `dcl lint` using the approach suggested at https://github.com/decentraland/sdk/issues/503
The `lint` command will also check for other files, like PNGs and GLTFs for errors. So it should not be entirely bound to a js/ts linter. It may be implemented as a high order function over a regular linter.
Contributor guide
Research direction
Start by reading the dependency issue #503 and the proposed lint implementation location in the dcl-rollup repository. Trace how the command should be exposed through dcl lint and installed with @dcl/sdk. Done requires checks for root-level side effects, empty imports, floating promises, and errors in PNG and GLTF files, with failures reported by the build checks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, typescript
- Domain
- build-system, cli, tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100