Skip to content

Conversation

@ksen0
Copy link
Member

@ksen0 ksen0 commented Nov 7, 2025

When preload() is used in a 2.x sketch, a blocking FES error appears, and explains that this function cannot be used in the same way. Since release of 2.0, the p5.js-compatibility resources has been improved, and can be included in this message.

Proposed message:

🌸 p5.js says: The preload() function has been removed in p5.js 2.0. Please load assets in setup() using async / await keywords or callbacks instead. See https://github.com/processing/p5.js-compatibility for more information about 2.0 and compatibility, or https://dev.to/limzykenneth/asynchronous-p5js-20-458f for more information about promises and async/await.

Sketch: https://editor.p5js.org/ksen0/sketches/GWgLNlsgi

Previous message:

🌸 p5.js says: The preload() function has been removed in p5.js 2.0. Please load assets in setup() using async / await keywords or callbacks instead. See https://dev.to/limzykenneth/asynchronous-p5js-20-458f for more information

@ksen0 ksen0 merged commit c988e29 into dev-2.0 Nov 7, 2025
5 checks passed
@ksen0 ksen0 deleted the preload-message branch November 7, 2025 18:57
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.

4 participants