Skip to content

Fix bundling lazy load #75

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Jan 3, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,32 @@
<a name="3.1.0"></a>

### Bug Fixes
* **sandboxes.ts:** The `sandboxes.ts` file is no longer generated in the root of the consuming application's
project. Instead, `sandboxes.ts` is modified and referenced entirely within
`angular-playground` ([1fda77f](https://github.com/SoCreate/angular-playground/commit/1fda77f)).
* **sandbox chunking:** Sandbox scenarios are individually chunked and loaded, meaning that your
component sandboxes are once again truly isolated. This functionality
was affected by the `@angular/cli` 1.6.2 update
([1fda77f](https://github.com/SoCreate/angular-playground/commit/1fda77f)).

Before we had you change `tsconfig.app.json` to use `esnext` modules:
```
# tsconfig.app.json
{
...
"module": "esnext"
}
```

Now there's no need to change it from the Angular CLI's default:
```
# tsconfig.app.json
{
...
"module": "es2015"
}
```

<a name="3.0.0"></a>

# 3.0.0 (2017-12-01)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"project": {
"name": "angular-playground"
"name": "cli-example"
},
"apps": [
{
Expand All @@ -17,9 +17,9 @@
"test": "test.ts",
"tsconfig": "tsconfig.app.json",
"testTsconfig": "tsconfig.spec.json",
"prefix": "ex",
"prefix": "app",
"styles": [
"styles.scss"
"styles.css"
],
"scripts": [],
"environmentSource": "environments/environment.ts",
Expand All @@ -31,7 +31,7 @@
{
"name": "playground",
"root": "src",
"outDir": "dist-playground",
"outDir": "dist",
"assets": [
"assets",
"favicon.ico"
Expand All @@ -40,22 +40,31 @@
"main": "main.playground.ts",
"polyfills": "polyfills.ts",
"tsconfig": "tsconfig.app.json",
"prefix": "app",
"environmentSource": "environments/environment.ts",
"environments": {
"dev": "environments/environment.ts",
"prod": "environments/environment.prod.ts"
}
}
],
"e2e": {
"protractor": {
"config": "./protractor.conf.js"
}
},
"lint": [
{
"project": "src/tsconfig.app.json"
"project": "src/tsconfig.app.json",
"exclude": "**/node_modules/**"
},
{
"project": "src/tsconfig.spec.json"
"project": "src/tsconfig.spec.json",
"exclude": "**/node_modules/**"
},
{
"project": "e2e/tsconfig.e2e.json"
"project": "e2e/tsconfig.e2e.json",
"exclude": "**/node_modules/**"
}
],
"test": {
Expand All @@ -64,7 +73,7 @@
}
},
"defaults": {
"styleExt": "scss",
"styleExt": "css",
"component": {}
}
}
Original file line number Diff line number Diff line change
@@ -1,26 +1,35 @@
# See http://help.github.com/ignore-files/ for more about ignoring files.

src/sandboxes.ts

# compiled output
/dist
/tmp
/out-tsc

# dependencies
/node_modules
/bower_components

# IDEs and editors
/.idea
/.vscode
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace

# IDE - VSCode
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json

# misc
/.sass-cache
/connect.lock
/coverage/*
/coverage
/libpeerconnection.log
npm-debug.log
testem.log
Expand All @@ -30,9 +39,6 @@ testem.log
/e2e/*.js
/e2e/*.map

#System Files
# System Files
.DS_Store
Thumbs.db
/debug.log
/src/sandboxes.ts
/src/my-sandboxes
27 changes: 27 additions & 0 deletions examples/cli-example/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# CliExample

This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 1.6.2.

## Development server

Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.

## Code scaffolding

Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.

## Build

Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `-prod` flag for a production build.

## Running unit tests

Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).

## Running end-to-end tests

Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).

## Further help

To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI README](https://github.com/angular/angular-cli/blob/master/README.md).
6 changes: 6 additions & 0 deletions examples/cli-example/angular-playground.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"sourceRoot": "src",
"angularCli": {
"appName": "playground"
}
}
14 changes: 14 additions & 0 deletions examples/cli-example/e2e/app.e2e-spec.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { AppPage } from './app.po';

describe('cli-example App', () => {
let page: AppPage;

beforeEach(() => {
page = new AppPage();
});

it('should display welcome message', () => {
page.navigateTo();
expect(page.getParagraphText()).toEqual('Welcome to app!');
});
});
11 changes: 11 additions & 0 deletions examples/cli-example/e2e/app.po.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { browser, by, element } from 'protractor';

export class AppPage {
navigateTo() {
return browser.get('/');
}

getParagraphText() {
return element(by.css('app-root h1')).getText();
}
}
14 changes: 14 additions & 0 deletions examples/cli-example/e2e/tsconfig.e2e.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/e2e",
"baseUrl": "./",
"module": "commonjs",
"target": "es5",
"types": [
"jasmine",
"jasminewd2",
"node"
]
}
}
Loading