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

plugins: tsconfig: add strictNullChecks #2919

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

DhairyaMajmudar
Copy link
Contributor

@DhairyaMajmudar DhairyaMajmudar commented Feb 18, 2025

Description

  1. Adding "strictNullChecks": true in typescript config file for plugins
  2. After adding so there were some build failures which are now fixed.

Fixes: #2911

Testing

  1. Run npm run build: Package is building fine w/o any warnings or errors

@dosubot dosubot bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Feb 18, 2025
Copy link
Contributor

@sniok sniok left a comment

Choose a reason for hiding this comment

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

thanks for taking a look into this!

plugins/headlamp-plugin project doesn't really have it's own typescript files, it only copies some from frontend/ project so setting strictNullChecks isn't very beneficial

I'd recommend starting from individual plugins in https://github.com/headlamp-k8s/plugins repo

or if you want to try working on the frontend/ part, you could try enabling strictNullChecks fixing some errors and then disabling it, so it's easier to do bit by bit and not all at once

@DhairyaMajmudar
Copy link
Contributor Author

thanks for taking a look into this!

plugins/headlamp-plugin project doesn't really have it's own typescript files, it only copies some from frontend/ project so setting strictNullChecks isn't very beneficial

I'd recommend starting from individual plugins in https://github.com/headlamp-k8s/plugins repo

or if you want to try working on the frontend/ part, you could try enabling strictNullChecks fixing some errors and then disabling it, so it's easier to do bit by bit and not all at once

Thank you for letting me know, let me first start with the frontend/ parts by parts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size:XS This PR changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enable strictNullChecks for frontend and plugins
2 participants