2018-12-27 23:23:13 +00:00
|
|
|
import * as plugins from './websetup.plugins';
|
|
|
|
|
2019-03-25 14:57:38 +00:00
|
|
|
import { setupGoogleAnalytics } from './tools/ganalytics';
|
2019-03-25 15:07:04 +00:00
|
|
|
import { setupFullStory } from './tools/fullstory';
|
2019-03-25 14:57:38 +00:00
|
|
|
|
|
|
|
export interface IWebSetupConstructorOptions {
|
|
|
|
googleAnalyticsCode?: string;
|
|
|
|
fsCode?: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* the main WebSetup class
|
|
|
|
*/
|
|
|
|
export class WebSetup {
|
|
|
|
constructor(optionsArg: IWebSetupConstructorOptions) {
|
|
|
|
if (optionsArg.googleAnalyticsCode) {
|
|
|
|
setupGoogleAnalytics(optionsArg.googleAnalyticsCode);
|
|
|
|
}
|
|
|
|
|
2019-03-25 15:07:04 +00:00
|
|
|
if (optionsArg.fsCode) {
|
|
|
|
setupFullStory(optionsArg.fsCode)
|
2019-03-25 14:57:38 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|