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

Enable strict mode for workspace-backpack #2030

Closed
1 task done
maribethb opened this issue Oct 20, 2023 · 1 comment · Fixed by #2080
Closed
1 task done

Enable strict mode for workspace-backpack #2030

maribethb opened this issue Oct 20, 2023 · 1 comment · Fixed by #2080
Assignees
Labels
help wanted Open for contributions size: small type: feature request New feature or request

Comments

@maribethb
Copy link
Contributor

Check for duplicates

  • I have searched for similar issues before opening a new one.

Component

workspace-backpack

Problem

No response

Request

The workspace-backpack plugin does not have "strict mode" enabled for TypeScript. We should enable it to have better type checking for our plugins, but doing so may show some TypeScript errors that need to be fixed first.

This would be a good first issue for anyone experienced with working in TypeScript. You may need to adjust types, add checks for null or undefined, or make other fixes. If you have questions, feel free to ask here! In general, the team prefers avoiding casts and using ! to coerce non-null types, and instead adding appropriate checks.

To work on this issue:

  1. Run npm install at the root of Blockly samples to set up dependencies.
  2. Navigate to the plugin's directory
  3. Change strict: false to strict: true in the plugin's tsconfig.json
  4. Run npm run build and see if there are any TypeScript errors.
  5. Resolve any TypeScript errors, if present. If not, then we got lucky and accidentally wrote strict code! Yay!
  6. Run npm run build again to make sure there are no TypeScript errors.
  7. Run npm run start and play with the plugin in the playground to make sure the plugin still behaves as expected.
  8. Run npm run test to run any automated tests.
  9. Run npm run lint to make sure there are no formatting errors.
  10. Open a PR with your changes!

Alternatives considered

No response

Additional context

No response

@maribethb maribethb added type: feature request New feature or request triage help wanted Open for contributions size: small and removed triage labels Oct 20, 2023
@sdthaker
Copy link
Contributor

Would like to work on this one if it's up for grabs! Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Open for contributions size: small type: feature request New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants