Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update devDependencies, fix eslint, use ES6 #330

Merged
merged 11 commits into from
Aug 5, 2022
Merged

Conversation

afshin
Copy link
Member

@afshin afshin commented Aug 4, 2022

This PR:

  • Updates to ES6 everywhere
  • Updates to lerna
  • Fixes eslint errors and warnings
  • Updates rollup
  • Updates webpack

With this PR

$ eslint --ext .js,.jsx,.ts,.tsx --cache --fix .
✨  Done in 1.57s.

Before this PR

$ eslint --ext .js,.jsx,.ts,.tsx --cache --fix .
=============

WARNING: You are currently running a version of TypeScript which is not officially supported by @typescript-eslint/typescript-estree.

You may find that it works just fine, or you may not.

SUPPORTED TYPESCRIPT VERSIONS: >=3.3.1 <4.2.0

YOUR TYPESCRIPT VERSION: 4.7.4

Please only submit bug reports when using the officially supported version.

=============

/Users/af/Code/lumino/packages/datagrid/src/celleditor.ts
   832:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
   845:25  warning  Argument 'value' should be typed with a non-any type  @typescript-eslint/explicit-module-boundary-types
   853:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
   863:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
   934:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
   985:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
  1052:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
  1065:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
  1174:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
  1187:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
  1280:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
  1295:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
  1466:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
  1479:3   warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types

/Users/af/Code/lumino/packages/datagrid/src/celleditorcontroller.ts
  119:3  warning  Missing return type on function  @typescript-eslint/explicit-module-boundary-types

/Users/af/Code/lumino/packages/datagrid/src/datamodel.ts
  153:5  warning  Argument 'value' should be typed with a non-any type  @typescript-eslint/explicit-module-boundary-types

/Users/af/Code/lumino/packages/datagrid/src/graphicscontext.ts
   93:20  warning  'CanvasTextAlign' is not defined           no-undef
   97:24  warning  'CanvasTextAlign' is not defined           no-undef
  104:23  warning  'CanvasTextBaseline' is not defined        no-undef
  108:27  warning  'CanvasTextBaseline' is not defined        no-undef
  115:18  warning  'CanvasLineCap' is not defined             no-undef
  119:22  warning  'CanvasLineCap' is not defined             no-undef
  137:19  warning  'CanvasLineJoin' is not defined            no-undef
  141:23  warning  'CanvasLineJoin' is not defined            no-undef
  236:35  warning  'GlobalCompositeOperation' is not defined  no-undef
  240:39  warning  'GlobalCompositeOperation' is not defined  no-undef
  318:50  warning  'CanvasFillRule' is not defined            no-undef
  408:19  warning  'CanvasFillRule' is not defined            no-undef
  416:19  warning  'CanvasFillRule' is not defined            no-undef
  489:3   warning  Missing return type on function            @typescript-eslint/explicit-module-boundary-types

/Users/af/Code/lumino/packages/domutils/src/selector.ts
  117:32  warning  Don't use `Function` as a type. The `Function` type accepts any function-like value.
It provides no type safety when calling the function, which can be a common source of bugs.
It also accepts things like class declarations, which will throw at runtime as they will not be called with `new`.
If you are expecting the function to accept certain arguments, you should explicitly define the function shape  @typescript-eslint/ban-types

/Users/af/Code/lumino/packages/properties/src/index.ts
  225:29  warning  Argument 'owner' should be typed with a non-any type  @typescript-eslint/explicit-module-boundary-types
  261:29  warning  Argument 'owner' should be typed with a non-any type  @typescript-eslint/explicit-module-boundary-types

/Users/af/Code/lumino/packages/signaling/src/index.ts
  150:29  warning  Argument 'thisArg' should be typed with a non-any type        @typescript-eslint/explicit-module-boundary-types
  164:32  warning  Argument 'thisArg' should be typed with a non-any type        @typescript-eslint/explicit-module-boundary-types
  199:37  warning  Argument 'sender' should be typed with a non-any type         @typescript-eslint/explicit-module-boundary-types
  199:50  warning  Argument 'receiver' should be typed with a non-any type       @typescript-eslint/explicit-module-boundary-types
  208:36  warning  Argument 'sender' should be typed with a non-any type         @typescript-eslint/explicit-module-boundary-types
  222:38  warning  Argument 'receiver' should be typed with a non-any type       @typescript-eslint/explicit-module-boundary-types
  236:33  warning  Argument 'object' should be typed with a non-any type         @typescript-eslint/explicit-module-boundary-types
  249:29  warning  Argument 'object' should be typed with a non-any type         @typescript-eslint/explicit-module-boundary-types
  315:5   warning  Argument 'thisArg' should be typed with a non-any type        @typescript-eslint/explicit-module-boundary-types
  366:5   warning  Argument 'thisArg' should be typed with a non-any type        @typescript-eslint/explicit-module-boundary-types
  405:37  warning  Argument 'sender' should be typed with a non-any type         @typescript-eslint/explicit-module-boundary-types
  405:50  warning  Argument 'receiver' should be typed with a non-any type       @typescript-eslint/explicit-module-boundary-types
  441:36  warning  Argument 'sender' should be typed with a non-any type         @typescript-eslint/explicit-module-boundary-types
  474:38  warning  Argument 'receiver' should be typed with a non-any type       @typescript-eslint/explicit-module-boundary-types
  507:33  warning  Argument 'object' should be typed with a non-any type         @typescript-eslint/explicit-module-boundary-types
  585:5   warning  Do not use "@ts-ignore" because it alters compilation errors  @typescript-eslint/ban-ts-comment

/Users/af/Code/lumino/packages/widgets/src/docklayout.ts
  2084:10  warning  Missing return type on function  @typescript-eslint/explicit-module-boundary-types
  2097:10  warning  Missing return type on function  @typescript-eslint/explicit-module-boundary-types

/Users/af/Code/lumino/packages/widgets/src/dockpanel.ts
  880:9  warning  Unexpected lexical declaration in case block  no-case-declarations

/Users/af/Code/lumino/packages/widgets/src/tabbar.ts
  1776:18  warning  'ClientRect' is not defined  no-undef

/Users/af/Code/lumino/packages/widgets/src/widget.ts
  778:17  warning  'HTMLElementTagNameMap' is not defined  no-undef

/Users/af/Code/lumino/scripts/format-changelog.js
  6:7  warning  'package' is assigned a value but never used  @typescript-eslint/no-unused-vars

✖ 55 problems (0 errors, 55 warnings)

✨  Done in 6.60s.

cf. #325

@afshin afshin added the maintenance Dependencies, build, technical debt, etc. label Aug 4, 2022
@afshin afshin added this to the Lumino 2 milestone Aug 4, 2022
@afshin afshin self-assigned this Aug 4, 2022
@afshin afshin marked this pull request as draft August 4, 2022 13:52
@afshin afshin mentioned this pull request Aug 4, 2022
16 tasks
@afshin afshin marked this pull request as ready for review August 4, 2022 15:24
@afshin afshin changed the title Use ES6 everywhere and fix eslint Use ES6 everywhere, fix eslint, update lerna Aug 4, 2022
@afshin afshin changed the title Use ES6 everywhere, fix eslint, update lerna Update more devDependencies, fix eslint, use `ES6 Aug 4, 2022
@afshin afshin changed the title Update more devDependencies, fix eslint, use `ES6 Update more devDependencies, fix eslint, use ES6 Aug 4, 2022
@afshin afshin marked this pull request as draft August 4, 2022 22:07
@afshin afshin marked this pull request as ready for review August 4, 2022 22:41
Copy link
Member

@fcollonval fcollonval left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot @afshin

I got a few suggestions.

"husky": "^4.2.5",
"lerna": "^4.0.0",
"lerna": "^5.3.0",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉 we should definitely bring that to JLab

.eslintrc.js Outdated Show resolved Hide resolved
package.json Show resolved Hide resolved
Comment on lines +69 to +70
"webpack": "^5.74.0",
"webpack-cli": "^4.10.0"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is probably out of scope for this PR. But it will be nice to drop webpack because it is inconsistent to distribute lumino using rollup but testing it using webpack.

afshin and others added 4 commits August 5, 2022 10:06
Co-authored-by: Frédéric Collonval <fcollonval@users.noreply.github.com>
Co-authored-by: Frédéric Collonval <fcollonval@users.noreply.github.com>
@afshin afshin merged commit 129221f into jupyterlab:main Aug 5, 2022
@afshin afshin changed the title Update more devDependencies, fix eslint, use ES6 Update devDependencies, fix eslint, use ES6 Aug 8, 2022
@afshin afshin removed their assignment Aug 8, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 9, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
maintenance Dependencies, build, technical debt, etc.
Projects
No open projects
Status: done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants