Skip to content

Handle minified conditionals in p5.strands - #9364

Merged
davepagurek merged 3 commits into
mainfrom
strands-minified-conditionals
Nov 3, 2026
Merged

davepagurek merged 3 commits into
mainfrom
strands-minified-conditionals

Conversation

@davepagurek

@davepagurek davepagurek commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

Resolves #9363

Changes:

  • When we see something that does some boolean operations, e.g. &&, ||, or a ternary, but where the result is not read by anything, it interprets this as a minified conditional and turns it back into an if
    • If the result IS read, like in an if condition, it's left alone. You may then get an error if you were trying to do boolean operations on non-boolean values, e.g. a bool and a number.
  • Removes numbering in comments about transpiler phases + fixes a bit of indentation, it gets annoying having to update all the numbers each time

Live: https://editor.p5js.org/davepagurek/sketches/__lt-rf8P

PR Checklist

@p5-bot

p5-bot Bot commented Nov 2, 2026 •

Copy link
Copy Markdown

Continuous Release

CDN link

Published Packages

Commit hash: c2c0708

Previous deployments

123a252


This is an automated message.

@ksen0 ksen0 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thank you!

@davepagurek
davepagurek merged commit 65e96de into main Nov 3, 2026
7 checks passed
@davepagurek
davepagurek deleted the strands-minified-conditionals branch November 3, 2026 00:25
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.

[p5.js 2.0+ Bug Report]: [RC] minified p5 has errors on filter(BLUR)

2 participants