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

Shorthand for IS_BUILD_MODE #2268

Open
wants to merge 12 commits into
base: main
Choose a base branch
from
Open

Shorthand for IS_BUILD_MODE #2268

wants to merge 12 commits into from

Conversation

mcgear
Copy link
Contributor

@mcgear mcgear commented Jan 19, 2024

This is a quick shorthand for IS_BUILD_MODE (Deno.args.includes("build")), should help simplify code that needs to not run during ahead of time builds. Will address #2240 .

Copy link
Contributor

@deer deer left a comment

Choose a reason for hiding this comment

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

My standard comment: tests?

Although you could probably get away in this case without writing anything new if you just refactor the one place in the codebase that uses this line to use your new const:

if (Deno.args.includes("build")) {

This is executed in the tests, so if it works here, I'd say it's covered.

@mcgear
Copy link
Contributor Author

mcgear commented Jan 28, 2024

This change has been put in place. Thanks for the thoughts.

@mcgear
Copy link
Contributor Author

mcgear commented Jan 31, 2024

Just updated the branch

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.

None yet

2 participants