refactor(WebWorker): Make WebWorker bootstrap synchronous
BREAKING CHANGE From the app thread, in both TypeScript and Dart, you bootstrap the app using `application` instead of `asyncApplication`. Before: ```TypeScript platform([WORKER_APP_PLATFORM]) .asyncApplication(setupWebWorker, optionalProviders?) .then((ref) => ref.bootstrap(RootComponent)); ``` Now: ```TypeScript platform([WORKER_APP_PLATFORM]) .application([WORKER_APP_APPLICATION]) .bootstrap(RootComponent); ``` closes #5857 Closes #5862
This commit is contained in:
@@ -4,7 +4,7 @@ import 'package:angular2/src/platform/server/html_adapter.dart';
|
||||
import "package:angular2/testing_internal.dart";
|
||||
import "package:angular2/src/core/reflection/reflection_capabilities.dart";
|
||||
import "package:angular2/src/core/reflection/reflection.dart";
|
||||
import "package:angular2/src/platform/worker_app_common.dart" show WORKER_APP_COMMON_PROVIDERS;
|
||||
import "package:angular2/src/platform/worker_app_common.dart" show WORKER_APP_APPLICATION_COMMON;
|
||||
import "package:angular2/platform/worker_app.dart" show WORKER_APP_PLATFORM;
|
||||
import "package:angular2/core.dart";
|
||||
import "../shared/web_worker_test_util.dart";
|
||||
@@ -19,7 +19,7 @@ main() {
|
||||
reflector.reflectionCapabilities = new ReflectionCapabilities();
|
||||
var buses = createPairedMessageBuses();
|
||||
platform([WORKER_APP_PLATFORM])
|
||||
.application([WORKER_APP_COMMON_PROVIDERS]);
|
||||
.application([WORKER_APP_APPLICATION_COMMON]);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user