Today I made the decision to add versioning to our application. What I really wanted was to get the version number of the package json and render it on a html page.
If you’re using typescript 2.9+
Simply import the version from the package json like this:
import {Version} from '../package.json';
And do not to forget to add theresolveJsonModule
inside your tsconfig.json
"resolveJsonModule": true
Thanks for reading and happy coding!