How to manually modify the P5js plugin (stable version) to use the 2.0 version?

Hello,

I mean, is it possible to replace the current stable version with the 2.0 version ?

Is it possible ?

:slight_smile:

P.S. As I am rewriting my project to integrate 3D, it would be a good time for me to work with the version 2 of P5js.
I prefer to use the Processing editor, because it’s easier to use git with it rather than having to use the web editor and have to download everything each time.

(I can’t use the new plugin version because it doesn’t work with Linux for now)

Hello,

I can’t get the p5.js Mode (experimental) to work with W10 or W11:

This is as far as it gets:

I run the sketch and there is no response.

Any ideas?

p5.js Mode (experimental) links to this p5.js Electron mode for Processing:

Note: I loosely used the term plugin before and updated post for clarity.

Personally I use VSC (Visual Studio Code) for all my p5js as it integrates well with github and requires no plugin simply add this link in the web page header

<script src="https://cdn.jsdelivr.net/npm/p5@2.2.2/lib/p5.js"></script>

Simply change the 2.2.2 to the release you want to use.

This nudged me to try this…

I was up and running in moments with the Using VS Code guide here:

It already provides the the 2.2.2/lib/p5.min.js which I replaced with the full version version:

   <!-- <script src="https://cdn.jsdelivr.net/npm/p5@2.2.2/lib/p5.min.js"></script> -->
    <script src="https://cdn.jsdelivr.net/npm/p5@2.2.2/lib/p5.js"></script>

:)

I found how to use P5js2 in the Processing editor with the current plugin!!!

It’s just silly actually, lol.

Just change the index.html page manually!!!

The editor modify index.html only when you change something in the tabs!!!

:face_with_hand_over_mouth:

and to find the lines to insert, just use the web editor, check the right boxes, and save the sketch!

A copy / paste on the lines in the downloaded index.html file et voilĂ  !

and you can delete the librairy folder

:rofl:

N.B. The library folder is created each time you open a p5js sketch

So, I delete it before each commit (It’s not a problem. You just have to know it!)

Hello folks!

You can also create custom template that is used when p5.js Mode 1.6 is used with the Processing PDE:

Make a backup of the template folder so you can restore it.

:)

Great !!!

(you can’t delete the libraries folder but it can be empty)

:slight_smile: