At the moment it is not possible to share common code across multiple JavaScript extensions.
To simplify development of multiple similar extensions, it would be very useful if those extensions could be build on simple library(ies) of shared, efficient tested and reliable code.
Goal: provide and document ability to develop and deploy such common code library(ies) within a tenant.
This is by design, however below enhancement request has been created to improve this javascript deployment in APM
US965250 - common JavaScripts
" Users can define common javascript code. Users can mark the checkbox to include all common code to his/her
javascript while executed. This will opt-out by default common javascript code from the existing extensions.
There will be only one common javascript code that can be included to the marked extensions."
For an update contact Broadcom Support