#682·framework

Add version headers to distributed library files

Author: ckotzbauerCreated Dec 22, 2016Updated May 24, 2022
Labelsenhancementdocumentation

I'm submitting a feature request

  • Library Version: doesn't matter

Please tell us about your environment: Environment doesn't matter here

Current behavior: There is no way to find out which specific version of a aurelia library file is used in an application.

Expected/desired behavior: Add a short version header to each distributed file of all aurelia libraries. E.g: /* aurelia-bootstrapper 2.0.0; https://aurelia.io/ */ Or something similar to this.

What is the motivation / use case for changing the behavior? An information like this is needed if your application does not use the library files directly from node_modules. In some of my projects I copy the needed files to another directory and push them to git (Reason for this is, because I want to have full control about version updates). This problem can be resolved with three solutions:

  • A version header is included in each file (like described above)
  • I have to copy the package.json files of each npm module to the corresponding location in my project directory.
  • I have to remove version range characters in my package.json to avoid implicit updates in node_modules. But this only affects top-level dependencies.