0👍
✅
You can wrap your Chartjs code (i.e. by changing your Chart.js file) to check for the existence of the global variable Chart (window.Chart !== undefined
) before running the wrapped the code.
That said, what you should probably be doing is have a modular structure with each of your Jenkins modules (plugins) depend on the Chart.js module. See http://requirejs.org/ for one way to do this.