Skip to content

[ZEPPELIN-6372] Reimplement custom TSLint rules as ESLint rules#5279

Open
voidmatcha wants to merge 1 commit into
apache:masterfrom
voidmatcha:ZEPPELIN-6372
Open

[ZEPPELIN-6372] Reimplement custom TSLint rules as ESLint rules#5279
voidmatcha wants to merge 1 commit into
apache:masterfrom
voidmatcha:ZEPPELIN-6372

Conversation

@voidmatcha

@voidmatcha voidmatcha commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

What is this PR for?

PR #5109 removed all TSLint code from zeppelin-web-angular. This restores the two custom lint rules on the ESLint flat config as a local plugin at zeppelin-web-angular/eslint-rules:

  • constructor-params-order (ZEPPELIN-6301): constructor parameters must be ordered public, protected, private, with optional and @Optional() parameters last.
  • ordered-exports (ZEPPELIN-6325): top-level exports in public-api.ts barrels must be alphabetically ordered by module specifier.

Both are registered in eslint.config.js and enforced by the existing husky/lint-staged pre-commit hook that runs eslint --fix on staged .ts files. Logic and autofix are ported from the original TSLint rules onto the typescript-eslint AST. The rules are plain CommonJS, matching eslint.config.js.

eslint src projects reports no violations on the current tree, so no existing code changes are required.

What type of PR is it?

Improvement

What is the Jira issue?

https://issues.apache.org/jira/browse/ZEPPELIN-6372

How should this be tested?

  • cd zeppelin-web-angular && npm run lint passes.
  • Add an out-of-order constructor parameter, or an unsorted export in a public-api.ts, then run eslint --fix and confirm the rule flags and reorders it.

Questions:

  • Does the license files need to update? No.
  • Is there breaking changes for older versions? No.
  • Does this needs documentation? No.

Signed-off-by: YONGJAE LEE <dev.yongjaelee@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant