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

Migrate codebase to typescript #57

Merged
merged 19 commits into from
Feb 23, 2024
Merged

Migrate codebase to typescript #57

merged 19 commits into from
Feb 23, 2024

Conversation

Tristan-WorkGH
Copy link
Contributor

No description provided.

@Tristan-WorkGH Tristan-WorkGH added documentation Improvements or additions to documentation enhancement New feature or request labels Jan 8, 2024
@Tristan-WorkGH Tristan-WorkGH self-assigned this Jan 8, 2024
@Tristan-WorkGH Tristan-WorkGH requested review from SlimaneAmar and flomillot and removed request for achour94 January 12, 2024 10:00
@@ -4,6 +4,10 @@
"license": "MPL-2.0",
"homepage": ".",
"private": true,
"engines": {
Copy link
Contributor

Choose a reason for hiding this comment

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

I already tried to add this when I arrived long time ago but apparently we should not, so I think you can remove this part

Copy link
Contributor Author

Choose a reason for hiding this comment

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

why? I'm interested of the reason.

Copy link
Contributor

@flomillot flomillot Jan 22, 2024

Choose a reason for hiding this comment

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

Honestly I don't know, I don't remember.
Cf these PR never merged :
gridsuite/gridstudy-app#814
gridsuite/gridstudy-app#766

Copy link
Contributor

@flomillot flomillot Jan 22, 2024

Choose a reason for hiding this comment

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

src/components/parameters.tsx Outdated Show resolved Hide resolved
src/rest/study.ts Show resolved Hide resolved
Copy link
Contributor

@TheMaskedTurtle TheMaskedTurtle left a comment

Choose a reason for hiding this comment

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

I think we can discuss about it, but for a lot of them you define types that don't bring any value. Using typescript, you must first let it infer what it can infer especially for function return types, then add specific types when it brings value and readability to our code. It is a bad practice to use types of types that comes for other libs with a lot of templating and all, we must define types that make sense for us and for our code, and it's compiler role to make sure that our defined types match to the signature of functions we call.

src/components/app-top-bar.tsx Show resolved Hide resolved
src/utils/rest-api.ts Outdated Show resolved Hide resolved
src/components/app-top-bar.tsx Outdated Show resolved Hide resolved
src/components/app-wrapper.tsx Outdated Show resolved Hide resolved
src/components/app-wrapper.tsx Outdated Show resolved Hide resolved
src/redux/reducer.ts Outdated Show resolved Hide resolved
src/redux/reducer.ts Show resolved Hide resolved
src/utils/rest-api.ts Outdated Show resolved Hide resolved
src/utils/rest-api.ts Show resolved Hide resolved
src/utils/rest-api.ts Show resolved Hide resolved
src/components/app-wrapper.tsx Outdated Show resolved Hide resolved
src/components/app-wrapper.tsx Show resolved Hide resolved
src/components/app.tsx Outdated Show resolved Hide resolved
src/components/parameters.tsx Outdated Show resolved Hide resolved
src/components/parameters.tsx Outdated Show resolved Hide resolved
src/redux/reducer.ts Outdated Show resolved Hide resolved
src/utils/rest-api.ts Outdated Show resolved Hide resolved
src/utils/rest-api.ts Outdated Show resolved Hide resolved
src/utils/rest-api.ts Outdated Show resolved Hide resolved
src/utils/rest-api.ts Outdated Show resolved Hide resolved
Tristan-WorkGH and others added 2 commits February 21, 2024 19:52
Co-authored-by: Joris Mancini <[email protected]>
Signed-off-by: Tristan Chuine <[email protected]>
src/components/app-top-bar.tsx Show resolved Hide resolved
src/components/parameters.tsx Outdated Show resolved Hide resolved
src/rest/study.ts Outdated Show resolved Hide resolved
src/utils/rest-api.ts Outdated Show resolved Hide resolved
@Tristan-WorkGH Tristan-WorkGH merged commit 259e7df into main Feb 23, 2024
2 checks passed
@Tristan-WorkGH Tristan-WorkGH deleted the migrate_ts branch February 23, 2024 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants