Fix: example.js stores defaultHTML function reference instead of calling it, causing examples to display raw JavaScript source in preview
Maintainers usually reply within 3 days
@syedbarkath980 is already working on this.
Since Oct 4, 2026.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 76/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- javascript
- Domain
- frontend
Research direction
Start at example.js and trace how the defaultHTML function is used when examples are fetched and shown in the preview panel. Reproduce the issue with npm run fetch-examples and npm start, then verify that opening an example renders an HTML page and runs the p5.js sketch instead of displaying JavaScript source.
Written by the indexing model from the issue text.
Description
p5.js version
v18.20.8
What is your operating system?
Windows
Web browser and version
Brave1.96.61 Chromium: 154.0.8037.98 (Official Build) (64-bit)
Actual Behavior
Bug Description
When running npm run fetch-examples locally, opening any example sketch
shows raw JavaScript function source code in the preview panel instead of
rendering a proper HTML page.
The preview panel displays raw JavaScript function source code:
Expected Behavior
The preview panel renders a proper HTML page that runs the p5.js sketch.
Steps to Reproduce:
- Clone the repository and complete manual installation
- Run
npm run fetch-examples - Start the server with
npm start - Open any example sketch from File → Examples
- Observe the preview panel
https://github.com/user-attachments/assets/26ab75c4-21c7-4937-8e80-c75395302137
- Dominant language
- JavaScript
- Stars
- 1.7k
- Forks
- 1.7k
- Avg merge
- 5d 16h
- Merged PRs (30d)
- 8
Getting set up
- Ships a Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from processing/p5.js-web-editor
-
Renaming a folder doubles the folder name in file paths (console errors show /lib/lib/helper.js)OpenAwaiting Maintainer Approval Bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
processing/p5.js-web-editor#4365 · 1 comment ·
Maintainers usually reply within 3 days
-
p5 logo is broken on verification emailsPossibly taken @sourabh65mehta claimed this 5 days ago. OpenBug
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
processing/p5.js-web-editor#4364 · 2 comments · 1 assignee ·
Maintainers usually reply within 3 days
-
`PATCH /editor/project/visibility` returns 200 with `null` and doesn't update when `projectId` is a slugMay be free again @Prbhtsgh claimed this 12 days ago, and no pull request is open. OpenAwaiting Maintainer Approval Bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
processing/p5.js-web-editor#4348 · 3 comments ·
Maintainers usually reply within 3 days
-
signup form gets stuck when signup request fails due to network errorPossibly taken @PS01K claimed this 46 days ago. OpenAwaiting Maintainer Approval Bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
processing/p5.js-web-editor#4285 · 3 comments ·
Maintainers usually reply within 3 days
-
Enhancement: Memoize sketches list and pagination selectors in SketchList.jsx to prevent redundant rendering cyclesPossibly taken @nodeanurag claimed this 4 days ago. OpenEnhancement
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
processing/p5.js-web-editor#4270 · 2 comments · 1 assignee ·
Maintainers usually reply within 3 days
All issues in processing/p5.js-web-editor
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
fix(套件): test_bundle 往仓库的 preset/skills 写哨兵,并发跑的 test_installer 拷贝时撞 ENOENT(CI 红)Possibly taken @Miaotofu01 claimed this today. Openneeds-triage
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Miaotofu01/Study-Mate#216 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
-
beginner-friendly category:fixtures community enhancement first-timers-only good first issue hacktoberfest help wanted low hanging fruit micro-contribution type: task up-for-grabs
Difficulty 1/5 Under an hour Newbie friendliness 85/100
Berserk-hub150/skillhawk#229 · 1 comment ·
Maintainers usually reply within 8 days