1) I used to import it as "scripts" array of angular.json file but, when run on Firefox, I obtain this error:
Error: Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.
Most likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)
import { Scheduler } from '../scheduler/build/scheduler.module.js';
Everything is working fine unless I compile on SSR and I obtain this error when I try to run the server side code:
ReferenceError: self is not defined
at Module../libs/scheduler/build/scheduler.module.js (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:146751:38)
at __webpack_require__ (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:146425:30)
at Object../src/app/scheduling/modules/scheduler-widget/services/bryntum-popup-manager.service.ts (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:350690:31)
at __webpack_require__ (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:146425:30)
at Object../src/app/scheduling/modules/scheduler-widget/services/index.ts (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:350932:22)
at __webpack_require__ (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:146425:30)
at Object../src/app/scheduling/modules/scheduler-widget/components/bryntum-scheduler/bryntum-scheduler.component.ts (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:348387:20)
at __webpack_require__ (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:146425:30)
at Object../src/app/scheduling/modules/scheduler-widget/components/bryntum-scheduler/bryntum-scheduler.component.ngfactory.js (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:348303:12)
at __webpack_require__ (/Users/giovannipini/Documents/VZC/fsd.ui/dist/server.js:146425:30)
/*
Bryntum Scheduler 3.0.4
Copyright(c) 2020 Bryntum AB
https://bryntum.com/contact
https://bryntum.com/license
*/
const productName = 'scheduler';
var support = {
searchParams: 'URLSearchParams' in self,
iterable: 'Symbol' in self && 'iterator' in Symbol,
blob:
'FileReader' in self &&
'Blob' in self &&
(function() {
try {
new Blob();
return true
} catch (e) {
return false
}
})(),
formData: 'FormData' in self,
arrayBuffer: 'ArrayBuffer' in self
};