@angular/platform-browser 14.0.0-rc.3 → 14.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v14.0.0-rc.3
2
+ * @license Angular v14.0.0
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -235,13 +235,13 @@ const platformBrowserTesting = createPlatformFactory(platformCore, 'browserTesti
235
235
  */
236
236
  class BrowserTestingModule {
237
237
  }
238
- BrowserTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.0-rc.3", ngImport: i0, type: BrowserTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
239
- BrowserTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.0.0-rc.3", ngImport: i0, type: BrowserTestingModule, exports: [BrowserModule] });
240
- BrowserTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.0.0-rc.3", ngImport: i0, type: BrowserTestingModule, providers: [
238
+ BrowserTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.0", ngImport: i0, type: BrowserTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
239
+ BrowserTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.0.0", ngImport: i0, type: BrowserTestingModule, exports: [BrowserModule] });
240
+ BrowserTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.0.0", ngImport: i0, type: BrowserTestingModule, providers: [
241
241
  { provide: APP_ID, useValue: 'a' },
242
242
  { provide: NgZone, useFactory: createNgZone },
243
243
  ], imports: [BrowserModule] });
244
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.0-rc.3", ngImport: i0, type: BrowserTestingModule, decorators: [{
244
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.0", ngImport: i0, type: BrowserTestingModule, decorators: [{
245
245
  type: NgModule,
246
246
  args: [{
247
247
  exports: [BrowserModule],
package/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v14.0.0-rc.3
2
+ * @license Angular v14.0.0
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -47,9 +47,12 @@ export declare interface ApplicationConfig {
47
47
  }
48
48
 
49
49
  /**
50
- * Bootstraps an instance of an Angular application and renders a root component.
50
+ * Bootstraps an instance of an Angular application and renders a standalone component as the
51
+ * application's root component. More information about standalone components can be found in [this
52
+ * guide](guide/standalone-components).
51
53
  *
52
- * Note: the root component passed into this function *must* be a standalone one (should have the
54
+ * @usageNotes
55
+ * The root component passed into this function *must* be a standalone one (should have the
53
56
  * `standalone: true` flag in the `@Component` decorator config).
54
57
  *
55
58
  * ```typescript
@@ -62,23 +65,46 @@ export declare interface ApplicationConfig {
62
65
  * const appRef: ApplicationRef = await bootstrapApplication(RootComponent);
63
66
  * ```
64
67
  *
65
- * Note: this bootstrap method doesn't include [Testability](api/core/Testability) by default.
66
- * You can add [Testability](api/core/Testability) by getting the list of necessary providers
67
- * using `provideProtractorTestingSupport()` function and add them into the `options.providers`
68
- * array. Example:
68
+ * You can add the list of providers that should be available in the application injector by
69
+ * specifying the `providers` field in an object passed as the second argument:
70
+ *
71
+ * ```typescript
72
+ * await bootstrapApplication(RootComponent, {
73
+ * providers: [
74
+ * {provide: BACKEND_URL, useValue: 'https://yourdomain.com/api'}
75
+ * ]
76
+ * });
77
+ * ```
78
+ *
79
+ * The `importProvidersFrom` helper method can be used to collect all providers from any
80
+ * existing NgModule (and transitively from all NgModules that it imports):
81
+ *
82
+ * ```typescript
83
+ * await bootstrapApplication(RootComponent, {
84
+ * providers: [
85
+ * importProvidersFrom(SomeNgModule)
86
+ * ]
87
+ * });
88
+ * ```
89
+ *
90
+ * Note: the `bootstrapApplication` method doesn't include [Testability](api/core/Testability) by
91
+ * default. You can add [Testability](api/core/Testability) by getting the list of necessary
92
+ * providers using `provideProtractorTestingSupport()` function and adding them into the `providers`
93
+ * array, for example:
69
94
  *
70
95
  * ```typescript
71
96
  * import {provideProtractorTestingSupport} from '@angular/platform-browser';
72
97
  *
73
- * await bootstrapApplication(RootComponent, providers: [provideProtractorTestingSupport()]);
98
+ * await bootstrapApplication(RootComponent, {providers: [provideProtractorTestingSupport()]});
74
99
  * ```
75
100
  *
76
- * @param rootComponent A reference to a Standalone Component that should be rendered.
77
- * @param options Additional configuration for the bootstrap operation, see `ApplicationConfig` for
101
+ * @param rootComponent A reference to a standalone component that should be rendered.
102
+ * @param options Extra configuration for the bootstrap operation, see `ApplicationConfig` for
78
103
  * additional info.
79
104
  * @returns A promise that returns an `ApplicationRef` instance once resolved.
80
105
  *
81
106
  * @publicApi
107
+ * @developerPreview
82
108
  */
83
109
  export declare function bootstrapApplication(rootComponent: Type<unknown>, options?: ApplicationConfig): Promise<ApplicationRef>;
84
110
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@angular/platform-browser",
3
- "version": "14.0.0-rc.3",
3
+ "version": "14.0.0",
4
4
  "description": "Angular - library for using Angular in a web browser",
5
5
  "author": "angular",
6
6
  "license": "MIT",
@@ -11,9 +11,9 @@
11
11
  "tslib": "^2.3.0"
12
12
  },
13
13
  "peerDependencies": {
14
- "@angular/animations": "14.0.0-rc.3",
15
- "@angular/core": "14.0.0-rc.3",
16
- "@angular/common": "14.0.0-rc.3"
14
+ "@angular/animations": "14.0.0",
15
+ "@angular/core": "14.0.0",
16
+ "@angular/common": "14.0.0"
17
17
  },
18
18
  "peerDependenciesMeta": {
19
19
  "@angular/animations": {
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v14.0.0-rc.3
2
+ * @license Angular v14.0.0
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */