Skip to content

Latest commit

 

History

History
59 lines (39 loc) · 1.22 KB

README_dev.md

File metadata and controls

59 lines (39 loc) · 1.22 KB

Hints for developers

Updated on March 22, 2023


Documentation

Excellent guidance for writing jsdoc documentation:

Use jsdoc at the command line to generate on-line documentation:

npx jsdoc src -r --destination docs --readme ./README.md --package ./package.json

Versioning

Use npm version at the command line while in your package directory. This must be done after git committing all code changes.

npm version a.b.c
# or
npm version patch

Testing

VSCode

Using VSCode, you can do interactive testing by loading a file with javascript commands, setting breakpoints and then starting the debugger. Be sure to select "Run Current File" before hitting the "Start Debugging" button.

UVU

For ES 6 modules, uvu is the recommended test framework.

Install uvu as a dev dependency:

npm install uvu --save-dev

The package.json must be modified so that it has:

"scripts": {
  "test": "uvu"
},

With Uvu, you can write scripts with the normal ESM import statements. See the https://github.com/MazamaScience/air-monitor-algorithms project for examples.