buildchain - mckennatim/gitinfo GitHub Wiki
< home
js webpack babel ts react node npm build chains
Every few years you need to update all your packages and modify how you build projects. Past working build environments include spa
, spa1
, hooks
, hooks2
, and partially working build environments include hooks3'
v17and
v18`. Most articles create one build environment with its own node_modules for each project. I prefer creating multiple projects on top of one master package.json and node_modules shared by all projects.
Running git.sh 00-tag
which is globally available and lives in /home/tim/.scripts updates git, pushes to github and makes a copy of essential files to tags/00-tag
managing node and nvm versions for stack
- put an .nvmrc file in the root of the stack with just a sting like
v19.4.0
- before running an npm script for a project, run
nvm use
to grab that node version along with its correct npm version
useful tools and subtasks
npm npm-update
: to update package.json to all the latest package release versions- npx depcheck: for analyzing the dependencies in a project
updating @mckennatim libraries
- copy the es6 src directory to a directory in /iot
- replace references to the npm package with an import from
log
1/24/23
v18 stack has 0 vulnerabilities and iot/wsclient compiles and runs in th browser connection to the server and the mqtt broker
1/23/23
set up this page.
Continue to work on minimum viable mqtt client and minimally viable zone-timer
hooks2
seems to be the best working stack for iot. Uses node v14.15.4 (npm v6.14.10), [email protected], @[email protected] and [email protected]. MQTT runs as does range-timer.v17
has no iot and was used to selectively update parts of the tcard appv18
is a not complete updated stack. As of 1/22/23 only iot/wsclient compiles. I has basic react, routing and screen-size-detection/multiple-panes using history and context. The intent is to cerate a minimally viable wsmqtt client here. None of the tcard apps will run here as material ui won't work with v18.
refs
https://javascript.plainenglish.io/learn-5-optimization-tips-for-webpack-step-by-step-cc81eb41a1c7
https://snyk.io/blog/best-practices-create-modern-npm-package/