-
Notifications
You must be signed in to change notification settings - Fork 1
Development Process
Use npm link to develop Mirage and Thor locally.
Goal is to quickly make Mirage changes and see them appear on local Thor server, while conveniently pushing those changes to GitHub.
Strategy tells Thor to use @rocketsofawesome/mirage package from local Mirage build folder.
Go into local mirage folder, prepare project, and initialize npm link:
cd mirage
nvm use 10.15.3
npm install
# Compile project into build folder
npm run predeploy
# Initialize linking
npm link
Go into local thor folder, prepare project, and link to local mirage:
cd thor
nvm use 10.15.3
npm install
# Finalize linking
npm link @rocketsofawesome/mirage
Run Thor server:
npm run dev
Make change in local Mirage and then rebuild:
# Run in local mirage
npm run predeploy
Local Thor server should pick up changes and restart automatically.
When the feature is ready, run npm version patch to add a commit that updates version in package.json.
Merge PR and wait for new version to get published.
After published, update package on Thor:
npm install @rocketsofawesome/mirage@latest --save
Feel free to improve guide!