Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add p5.js to allow friendly error messages #45

Open
wants to merge 25 commits into
base: master
Choose a base branch
from

Conversation

schellenberg
Copy link

For beginning programmers, having p5js use the Friendly Error System (FES) by default is very useful for basic debugging. A description of the FES can be found at https://github.com/processing/p5.js/blob/main/contributor_docs/friendly_error_system.md

These changes add the un-minified version of p5.js to the project template, adds it to the list of template files in extension.ts, links to it by default in the index.html file (with comments explaining why/how to use p5.js or p5.min.js), and adds a p5.js download to the shell script that updates the p5 libraries.

For beginning programmers, having p5js use Friendly Error Messages by default is very useful for basic debugging.

These changes add the un-minified version of p5.js to the project template, link to it by default in the index.html file (with comments explaining why/how to use p5.js or p5.min.js), and adds p5.js to the shell script that updates the p5 libraries.
Providing new (and old!) programmers with warnings when they make common mistakes is incredibly helpful. Unfortunately, teaching students the tools required to provide this feedback in VS Code can be frustrating. The changes in this pull request include an .eslintrc.json file that provides warnings for common JS issues. While there are plenty of reasonable rules, I have found the included ones useful for beginning programmers. The config file includes all the p5js functions/variables as globals, so that they don't trigger warnings/errors with eslint.

The intended use case for this (and what I've done in the past, before finding your incredibly helpful extension) is to pre-install nodejs in the computer lab, then have students call `npm install -g eslint` once on day 1 of the semester.
Making a cs30 specific version of this extension. It would probably be better to just create a custom template that can be chosen when a new project is created, but this is a simple way to make it work for my classes for now.
implement changes from upstream
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.

1 participant