This is just an example which is not complete but gives some hints how to re-generate code while keeping your custom changes.
To simplify, custom development is committed directly on git master branch.
Generate the app with JHipster 4.13.3
yarn global add [email protected]
mkdir keep-changes
cd keep-changes