@angular/core 12.1.0-next.6 → 12.1.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 v12.1.0-next.6
2
+ * @license Angular v12.1.0
3
3
  * (c) 2010-2021 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -358,10 +358,16 @@
358
358
  r[k] = a[j];
359
359
  return r;
360
360
  }
361
- function __spreadArray(to, from) {
362
- for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
363
- to[j] = from[i];
364
- return to;
361
+ function __spreadArray(to, from, pack) {
362
+ if (pack || arguments.length === 2)
363
+ for (var i = 0, l = from.length, ar; i < l; i++) {
364
+ if (ar || !(i in from)) {
365
+ if (!ar)
366
+ ar = Array.prototype.slice.call(from, 0, i);
367
+ ar[i] = from[i];
368
+ }
369
+ }
370
+ return to.concat(ar || from);
365
371
  }
366
372
  function __await(v) {
367
373
  return this instanceof __await ? (this.v = v, this) : new __await(v);
@@ -22038,7 +22044,7 @@
22038
22044
  /**
22039
22045
  * @publicApi
22040
22046
  */
22041
- var VERSION = new Version('12.1.0-next.6');
22047
+ var VERSION = new Version('12.1.0');
22042
22048
 
22043
22049
  /**
22044
22050
  * @license
@@ -30280,20 +30286,41 @@
30280
30286
  rxjs.merge(isCurrentlyStable, isStable.pipe(operators.share()));
30281
30287
  }
30282
30288
  /**
30283
- * Bootstrap a new component at the root level of the application.
30289
+ * Bootstrap a component onto the element identified by its selector or, optionally, to a
30290
+ * specified element.
30284
30291
  *
30285
30292
  * @usageNotes
30286
30293
  * ### Bootstrap process
30287
30294
  *
30288
- * When bootstrapping a new root component into an application, Angular mounts the
30289
- * specified application component onto DOM elements identified by the componentType's
30290
- * selector and kicks off automatic change detection to finish initializing the component.
30295
+ * When bootstrapping a component, Angular mounts it onto a target DOM element
30296
+ * and kicks off automatic change detection. The target DOM element can be
30297
+ * provided using the `rootSelectorOrNode` argument.
30291
30298
  *
30292
- * Optionally, a component can be mounted onto a DOM element that does not match the
30293
- * componentType's selector.
30299
+ * If the target DOM element is not provided, Angular tries to find one on a page
30300
+ * using the `selector` of the component that is being bootstrapped
30301
+ * (first matched element is used).
30294
30302
  *
30295
30303
  * ### Example
30296
- * {@example core/ts/platform/platform.ts region='longform'}
30304
+ *
30305
+ * Generally, we define the component to bootstrap in the `bootstrap` array of `NgModule`,
30306
+ * but it requires us to know the component while writing the application code.
30307
+ *
30308
+ * Imagine a situation where we have to wait for an API call to decide about the component to
30309
+ * bootstrap. We can use the `ngDoBootstrap` hook of the `NgModule` and call this method to
30310
+ * dynamically bootstrap a component.
30311
+ *
30312
+ * {@example core/ts/platform/platform.ts region='componentSelector'}
30313
+ *
30314
+ * Optionally, a component can be mounted onto a DOM element that does not match the
30315
+ * selector of the bootstrapped component.
30316
+ *
30317
+ * In the following example, we are providing a CSS selector to match the target element.
30318
+ *
30319
+ * {@example core/ts/platform/platform.ts region='cssSelector'}
30320
+ *
30321
+ * While in this example, we are providing reference to a DOM node.
30322
+ *
30323
+ * {@example core/ts/platform/platform.ts region='domNode'}
30297
30324
  */
30298
30325
  ApplicationRef.prototype.bootstrap = function (componentOrFactory, rootSelectorOrNode) {
30299
30326
  var _this = this;