Permalink
Browse files

chore(demos): update demos build task to use app-scripts (#9830)

* chore(build): WIP getting ionic working with app-scripts

the tsconfig file change is just for testing, this will need to be
undone

* chore(demos): update tsconfig and gitignore for demos

update tsconfig and gitinogre for demos

* chore(build): WIP check in progress with building with app-scripts

this only works with demos/action-sheet currently

* refactor(demos): add custom copy config

add custom copy config

* chore(tsconfig): revert root tsconfig

* chore(demos): change import paths

* chore(demos): move sass config, add new tsconfig, update template

* chore(scripts): update demos tasks to use app scripts with folder name

tweak the createTempTsConfig function to include a path to read from,
move getFolderInfo into util to share

at this point you should be able to run `gulp demos.prod` with a folder
e.g. `--f=alert` and open the index of that test to see it. Doesn’t
work yet with all of the tests at once. Need to have ran `gulp
release.prepareReleasePackage` first.

* chore(build): WIP working on getting all of the demos building

* chore(demos): update demos task for app-scripts build

* chore(demos): fix tslint errors thrown by app-scripts

* chore(demos): get the demos working with fonts and variable file

* chore(demos): add watch task to the new prod task

* chore(demos): remove old demos.prod file and rename new one to it

* chore(npm): remove build npm script

* chore(demos): only log component name in url if one was passed
  • Loading branch information...
1 parent cd342c2 commit b69eed5220864dc0437ce4729a6a436599fb723b @brandyscarney brandyscarney committed with jgw96 Jan 3, 2017
Showing with 397 additions and 199 deletions.
  1. +2 βˆ’1 .gitignore
  2. +1 βˆ’1 demos/src/action-sheet/app.module.ts
  3. +1 βˆ’1 demos/src/alert/app.module.ts
  4. +1 βˆ’1 demos/src/button/app.module.ts
  5. +1 βˆ’1 demos/src/checkbox/app.module.ts
  6. +1 βˆ’1 demos/src/chip/app.module.ts
  7. +1 βˆ’1 demos/src/config/app.module.ts
  8. +1 βˆ’1 demos/src/datetime/app.module.ts
  9. +1 βˆ’1 demos/src/events/app.module.ts
  10. +1 βˆ’1 demos/src/fab/app.module.ts
  11. +1 βˆ’1 demos/src/icon/app.module.ts
  12. +1 βˆ’1 demos/src/infinite-scroll/app.module.ts
  13. +1 βˆ’1 demos/src/input/app.module.ts
  14. +1 βˆ’1 demos/src/item-reorder/app.module.ts
  15. +1 βˆ’1 demos/src/item-sliding/app.module.ts
  16. +1 βˆ’1 demos/src/item/app.module.ts
  17. +1 βˆ’1 demos/src/label/app.module.ts
  18. +1 βˆ’1 demos/src/list/app.module.ts
  19. +1 βˆ’1 demos/src/loading/app.module.ts
  20. +1 βˆ’1 demos/src/menu/app.module.ts
  21. +1 βˆ’1 demos/src/modal/app.module.ts
  22. +1 βˆ’1 demos/src/nav-params/app.module.ts
  23. +1 βˆ’1 demos/src/navbar/app.module.ts
  24. +1 βˆ’1 demos/src/navigation/app.module.ts
  25. +1 βˆ’1 demos/src/platform/app.module.ts
  26. +1 βˆ’1 demos/src/popover/app.module.ts
  27. +1 βˆ’1 demos/src/radio/app.module.ts
  28. +1 βˆ’1 demos/src/range/app.module.ts
  29. +1 βˆ’1 demos/src/refresher/app.module.ts
  30. +1 βˆ’1 demos/src/scroll/app.module.ts
  31. +1 βˆ’1 demos/src/searchbar/app.module.ts
  32. +1 βˆ’1 demos/src/segment/app.module.ts
  33. +1 βˆ’1 demos/src/select/app.module.ts
  34. +1 βˆ’1 demos/src/show-when/app.module.ts
  35. +1 βˆ’1 demos/src/slides/app.module.ts
  36. +1 βˆ’1 demos/src/tabs/app.module.ts
  37. +2 βˆ’2 demos/src/textarea/app.module.ts
  38. +2 βˆ’2 demos/src/title/app.module.ts
  39. +2 βˆ’2 demos/src/toast/app.module.ts
  40. +2 βˆ’2 demos/src/toggle/app.module.ts
  41. +2 βˆ’2 demos/src/toolbar/app.module.ts
  42. +29 βˆ’0 demos/src/tsconfig.json
  43. +6 βˆ’4 package.json
  44. +7 βˆ’0 scripts/demos/copy.config.js
  45. +2 βˆ’2 scripts/demos/demos.template.prod.html
  46. +0 βˆ’6 scripts/demos/entry.ts
  47. +5 βˆ’0 scripts/demos/main.ts
  48. +103 βˆ’0 scripts/demos/sass.config.js
  49. +77 βˆ’0 scripts/demos/variables.scss
  50. +4 βˆ’4 scripts/gulp/tasks/build.ts
  51. +94 βˆ’114 scripts/gulp/tasks/demos.prod.ts
  52. +2 βˆ’18 scripts/gulp/tasks/e2e.prod.ts
  53. +20 βˆ’4 scripts/gulp/util.ts
  54. +1 βˆ’1 tsconfig.json
View
@@ -34,7 +34,8 @@ demos/node_modules
demos/polyfills
demos/css
demos/fonts
-demos/src/**/*.js*
+demos/src/**/*.js
+demos/src/**/*.map
demos/src/**/*.ngfactory.ts
demos/src/**/*.d.ts
demos/src/**/*.metadata.json
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { ActionSheetController, IonicApp, IonicModule, Platform } from '../';
+import { ActionSheetController, IonicApp, IonicModule, Platform } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { AlertController, IonicApp, IonicModule } from '../';
+import { AlertController, IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule, Platform, NavController } from '../';
+import { IonicApp, IonicModule, Platform, NavController } from '../../ionic-angular';
if (!window.localStorage) {
Object.defineProperty(window, 'localStorage', new (function () {
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule, ViewChild } from '@angular/core';
-import { Events, IonicApp, IonicModule, Nav } from '../';
+import { Events, IonicApp, IonicModule, Nav } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { FabContainer, IonicApp, IonicModule } from '../';
+import { FabContainer, IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, Injectable, NgModule } from '@angular/core';
-import { InfiniteScroll, IonicApp, IonicModule } from '../';
+import { InfiniteScroll, IonicApp, IonicModule } from '../../ionic-angular';
/**
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule, ViewEncapsulation } from '@angular/core';
-import { IonicApp, IonicModule, NavController, reorderArray } from '../';
+import { IonicApp, IonicModule, NavController, reorderArray } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule, ViewEncapsulation } from '@angular/core';
-import { IonicApp, IonicModule, ItemSliding, ToastController } from '../';
+import { IonicApp, IonicModule, ItemSliding, ToastController } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule, LoadingController, NavController } from '../';
+import { IonicApp, IonicModule, LoadingController, NavController } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule, MenuController } from '../';
+import { IonicApp, IonicModule, MenuController } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule, ModalController, NavParams, ViewController } from '../';
+import { IonicApp, IonicModule, ModalController, NavParams, ViewController } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule, NavController, NavParams } from '../';
+import { IonicApp, IonicModule, NavController, NavParams } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
// Use the toolbar demo but pass in the demo name to change the title
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule, NavController } from '../';
+import { IonicApp, IonicModule, NavController } from '../../ionic-angular';
let pageNum = 2;
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule, Platform } from '../';
+import { IonicApp, IonicModule, Platform } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, ElementRef, NgModule, ViewChild } from '@angular/core';
-import { IonicApp, IonicModule, NavParams, PopoverController } from '../';
+import { IonicApp, IonicModule, NavParams, PopoverController } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, Injectable, NgModule } from '@angular/core';
-import { IonicApp, IonicModule, Refresher } from '../';
+import { IonicApp, IonicModule, Refresher } from '../../ionic-angular';
/**
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule, ViewEncapsulation } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -30,4 +30,4 @@ export class ApiDemoApp {
ApiDemoPage
]
})
-export class AppModule {}
+export class AppModule {}
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
// Use the toolbar demo but pass in the demo name to change the title
@@ -35,4 +35,4 @@ export class ApiDemoApp {
ApiDemoPage
]
})
-export class AppModule {}
+export class AppModule {}
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule, ToastController } from '../';
+import { IonicApp, IonicModule, ToastController } from '../../ionic-angular';
@Component({
@@ -76,4 +76,4 @@ export class ApiDemoApp {
ApiDemoPage
]
})
-export class AppModule {}
+export class AppModule {}
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -43,4 +43,4 @@ export class ApiDemoApp {
ApiDemoPage
]
})
-export class AppModule {}
+export class AppModule {}
@@ -1,5 +1,5 @@
import { Component, NgModule } from '@angular/core';
-import { IonicApp, IonicModule } from '../';
+import { IonicApp, IonicModule } from '../../ionic-angular';
@Component({
@@ -32,4 +32,4 @@ export class ApiDemoApp {
ApiDemoPage
]
})
-export class AppModule {}
+export class AppModule {}
@@ -0,0 +1,29 @@
+{
+ "compilerOptions": {
+ "allowUnreachableCode": false,
+ "declaration": true,
+ "emitDecoratorMetadata": true,
+ "experimentalDecorators": true,
+ "lib": [
+ "dom",
+ "es2015"
+ ],
+ "module": "es2015",
+ "moduleResolution": "node",
+ "noImplicitAny": false,
+ "removeComments": false,
+ "sourceMap": true,
+ "target": "es5",
+ "types": [
+ "jasmine"
+ ]
+ },
+ "include": [
+ "./**/*.ts"
+ ],
+ "compileOnSave": false,
+ "buildOnSave": false,
+ "atom": {
+ "rewriteTsconfig": false
+ }
+}
View
@@ -39,6 +39,7 @@
"zone.js": "~0.6.26"
},
"devDependencies": {
+ "@ionic/app-scripts": "0.0.48-201612291559",
"@ionic/commit-hooks": "1.0.3",
"@types/connect": "3.4.30",
"@types/del": "2.2.31",
@@ -122,17 +123,18 @@
"ts-node": "1.3.0",
"tslint": "3.15.1",
"tslint-ionic-rules": "0.0.7",
- "typescript": "2.0.9",
+ "typescript": "~2.0.10",
"vinyl": "1.2.0",
- "webpack": "2.1.0-beta.26",
+ "webpack": "^2.1.0-beta.27",
"yargs": "5.0.0"
},
"config": {
"commitizen": {
"path": "node_modules/ionic-cz-conventional-changelog"
- }
+ },
+ "ionic_copy": "./scripts/demos/copy.config.js"
},
"pre-push#master": [
"test"
]
-}
+}
@@ -0,0 +1,7 @@
+// we don't want to run copy for the demos, so just override the config for now
+module.exports = {
+ copyAssets: { },
+ copyIndexContent: { },
+ copyFonts: { },
+ copyPolyfills: { }
+}
Oops, something went wrong.

0 comments on commit b69eed5

Please sign in to comment.