processing / processing/p5.js-web-editor

Git import/preview

Open
#753 8 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Feature Request Help Wanted Priority:High
Dominant language
JavaScript
Stars
1.7k
Forks
1.7k
Avg merge
3d 4h
Merged PRs (30d)
8

Description

I have a new feature request :)

I just taught a workshop with the p5.js editor. Usually I teach this workshop in 6 hours but the editor made it possible for me to teach it in 3 hours, due to the quicker setup time. It makes a huge difference.

The big difficulty in preparation for me was in uploading all my content to the editor.

Here are the examples I wanted to upload: https://github.com/kylemcdonald/cv-examples

For example, on this page if you click "edit" then you can see it links to the editor: https://kylemcdonald.github.io/cv-examples/AverageBrightness/

What would be amazing is to be able to simply point to:

https://editor.p5js.org/git/https://github.com/kylemcdonald/cv-examples.git/AverageBrightness

And have the editor know that it needs to fetch the repo and check out the specific folder.

This way the workshop/class materials could be kept up to date on GitHub, hosted on GitHub pages, and made runnable/editable in the p5 editor without needing to constantly update each sketch.

Glitch has a "repo import" feature, but I don't know if that makes sense to import an entire repo. Every time you press "play" it would bring you back to the main "index.html" which would feel weird.

The functionality I'm imagining is most similar to the way that Google colab will start a new colab notebook from a GitHub URL, described here.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the p5.js web editor and the linked GitHub and Google Colab import examples; the issue names no repository files, tests, or entry points. Done would mean a URL can fetch a GitHub repository, open the specified folder as an editable sketch, and preserve the expected index.html behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
git, javascript
Domain
web-dev
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.