/*********************************************************************************************** * User Configuration. **********************************************************************************************/ const components = [ 'all', 'button', 'card', 'checkbox', 'dialog', 'grid-list', 'icon', 'input', 'list', 'menu', 'progress-bar', 'progress-circle', 'radio', 'sidenav', 'slider', 'slide-toggle', 'button-toggle', 'tabs', 'toolbar', 'tooltip', ]; /** User packages configuration. */ const packages: any = { '@p2-platform/core': { format: 'cjs', defaultExtension: 'js' }, // Set the default extension for the root package, because otherwise the demo-app can't // be built within the production mode. Due to missing file extensions. '.': { defaultExtension: 'js' } }; components.forEach(name => { packages[`@p2-platform/${name}`] = { format: 'cjs', defaultExtension: 'js' }; }); //////////////////////////////////////////////////////////////////////////////////////////////// /*********************************************************************************************** * Everything underneath this line is managed by the CLI. **********************************************************************************************/ const barrels: string[] = [ // Angular specific barrels. '@angular/core', '@angular/common', '@angular/compiler', '@angular/http', '@angular/forms', '@angular/router', '@angular/platform-browser', '@angular/platform-browser-dynamic', // Thirdparty barrels. 'rxjs', // App specific barrels. 'demo-app', 'button-toggle', 'gestures', 'live-announcer', 'portal', 'overlay', ...components /** @cli-barrel */ ]; const _cliSystemConfig = {}; barrels.forEach((barrelName: string) => { ( _cliSystemConfig)[barrelName] = { main: 'index' }; }); /** Type declaration for ambient System. */ declare var System: any; // Apply the CLI SystemJS configuration. System.config({ map: { '@angular': 'vendor/@angular', 'rxjs': 'vendor/rxjs', 'main': 'main.js' }, packages: _cliSystemConfig }); // Apply the user's configuration. System.config({ packages });