Because of how the Dockerfiles are constructed there is very little that is able to be shared amongst all of these images. A small refactoring would allow there to be a base image that installs everything, and then the versioned Dockerfiles would just run the npm install command.