Override some functions from another javascript file (summernote.js)
I am changing summernote-lite.js to extend it's functionality and now I'm facing an issue: new version lunches and what now? I have to change it again if I want to use it on my websites. I think the best for me is to override functions that are already in that file and store that in separate js file, but how to do it? For example here is beginning of the summernote-lite.js file: (function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? factory(require('jquery')) : typeof define === 'function' && define.amd ? define(['jquery'], factory) : (factory(global.jQuery)); }(this, (function ($1) { then here are couple functions that I want to override: var imageDialog = function (opt) { .... } Next: var ImageDialog = /* @class */ (function () { ... ImageDialog.prototype.initialize = function () { ... } ImageDialog.prototype.show = function () { ... } ImageDialog.prototype.showImageDialog = function () {