ember-source 7.2.0-beta.1 → 7.3.0-alpha.2
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.
- package/build-metadata.json +3 -3
- package/dist/dev/packages/@ember/-internals/deprecations/index.js +10 -0
- package/dist/dev/packages/@ember/-internals/glimmer/index.js +7 -7
- package/dist/dev/packages/@ember/-internals/metal/index.js +8 -8
- package/dist/dev/packages/@ember/-internals/routing/index.js +1 -1
- package/dist/dev/packages/@ember/-internals/runtime/lib/mixins/-proxy.js +3 -3
- package/dist/dev/packages/@ember/-internals/runtime/lib/mixins/comparable.js +5 -0
- package/dist/dev/packages/@ember/-internals/runtime/lib/mixins/target_action_support.js +1 -1
- package/dist/dev/packages/@ember/-internals/views/lib/system/event_dispatcher.js +1 -1
- package/dist/dev/packages/@ember/-internals/views/lib/views/core_view.js +1 -1
- package/dist/dev/packages/@ember/application/index.js +2 -2
- package/dist/dev/packages/@ember/application/instance.js +22 -2
- package/dist/dev/packages/@ember/array/index.js +3 -3
- package/dist/dev/packages/@ember/array/proxy.js +3 -3
- package/dist/dev/packages/@ember/component/helper.js +321 -1
- package/dist/dev/packages/@ember/component/index.js +3 -3
- package/dist/dev/packages/@ember/controller/index.js +2 -2
- package/dist/dev/packages/@ember/engine/index.js +3 -3
- package/dist/dev/packages/@ember/object/computed.js +2 -2
- package/dist/dev/packages/@ember/object/core.js +2 -2
- package/dist/dev/packages/@ember/object/index.js +4 -4
- package/dist/dev/packages/@ember/object/lib/computed/computed_macros.js +3 -3
- package/dist/dev/packages/@ember/object/lib/computed/reduce_computed_macros.js +1 -1
- package/dist/dev/packages/@ember/object/mixin.js +1 -1
- package/dist/dev/packages/@ember/object/observable.js +3 -3
- package/dist/dev/packages/@ember/object/promise-proxy-mixin.js +2 -2
- package/dist/dev/packages/@ember/renderer/index.js +1 -1
- package/dist/dev/packages/@ember/routing/-internals.js +1 -1
- package/dist/dev/packages/@ember/routing/lib/routing-service.js +0 -1
- package/dist/dev/packages/@ember/routing/lib/utils.js +1 -1
- package/dist/dev/packages/@ember/routing/route.js +4 -4
- package/dist/dev/packages/@ember/routing/router-service.js +0 -1
- package/dist/dev/packages/@ember/routing/router.js +3 -3
- package/dist/dev/packages/@ember/service/index.js +1 -1
- package/dist/dev/packages/@ember/utils/lib/compare.js +5 -2
- package/dist/dev/packages/@glimmer/node/index.js +2 -2
- package/dist/dev/packages/@glimmer/runtime/index.js +3 -3
- package/dist/dev/packages/@glimmer/tracking/index.js +1 -1
- package/dist/dev/packages/@glimmer/validator/index.js +1 -1
- package/dist/dev/packages/ember/version.js +1 -1
- package/dist/dev/packages/router_js/index.js +2 -2
- package/dist/dev/packages/shared-chunks/{alias-DpqL1qx6.js → alias-CT_thCad.js} +2 -2
- package/dist/dev/packages/shared-chunks/{api-C0PAtEgQ.js → api-Dz70AUL_.js} +6 -4
- package/dist/dev/packages/shared-chunks/{array-CVEnNWng.js → array-DvaweI_T.js} +1 -1
- package/dist/dev/packages/shared-chunks/{computed-BPCtuOxQ.js → computed-DGxbeUbf.js} +1 -6
- package/dist/dev/packages/shared-chunks/{curly-Ei5G8jhk.js → curly-DGUCLOud.js} +4 -5
- package/dist/dev/packages/shared-chunks/curly-brand-B_F79Dep.js +12 -0
- package/dist/dev/packages/shared-chunks/helper-brand-C9_8vvOf.js +12 -0
- package/dist/dev/packages/shared-chunks/{index-B3pPx1fL.js → index-D1AjYv31.js} +618 -1575
- package/dist/dev/packages/shared-chunks/{injected_property-CbBLr5jt.js → injected_property-DbXd6Gax.js} +1 -1
- package/dist/dev/packages/shared-chunks/outlet-CHFL7tun.js +135 -0
- package/dist/dev/packages/shared-chunks/{property_set-qCUylPEK.js → property_set-CVlVgdor.js} +1 -1
- package/dist/dev/packages/shared-chunks/{rehydrate-builder-C6k1XhET.js → rehydrate-builder-CsnkZkur.js} +1 -1
- package/dist/dev/packages/shared-chunks/{render-87_sKZ_k.js → render-CtH73XOv.js} +10 -5
- package/dist/dev/packages/shared-chunks/{serialize-builder-BlxBjwO-.js → serialize-builder-D1oAeiyl.js} +1 -1
- package/dist/dev/packages/shared-chunks/{set_properties-C4TSebH6.js → set_properties-CEUT_EJn.js} +2 -2
- package/dist/dev/packages/shared-chunks/setup-registry-DQ3c4Juo.js +951 -0
- package/dist/dev/packages/shared-chunks/{textarea-C4lYkaHj.js → textarea-DEvw4ezm.js} +1 -1
- package/dist/dev/packages/shared-chunks/tracked-57EW14Ny.js +253 -0
- package/dist/dev/packages/shared-chunks/tracked-value-DhyJmrhG.js +115 -0
- package/dist/dev/packages/shared-chunks/{unrecognized-url-error-BJHjL30Q.js → unrecognized-url-error-B8loxkay.js} +1 -1
- package/dist/prod/packages/@ember/-internals/deprecations/index.js +10 -0
- package/dist/prod/packages/@ember/-internals/glimmer/index.js +7 -7
- package/dist/prod/packages/@ember/-internals/metal/index.js +8 -8
- package/dist/prod/packages/@ember/-internals/routing/index.js +1 -1
- package/dist/prod/packages/@ember/-internals/runtime/lib/mixins/-proxy.js +3 -3
- package/dist/prod/packages/@ember/-internals/runtime/lib/mixins/comparable.js +5 -0
- package/dist/prod/packages/@ember/-internals/runtime/lib/mixins/target_action_support.js +1 -1
- package/dist/prod/packages/@ember/-internals/views/lib/system/event_dispatcher.js +1 -1
- package/dist/prod/packages/@ember/-internals/views/lib/views/core_view.js +1 -1
- package/dist/prod/packages/@ember/application/index.js +2 -2
- package/dist/prod/packages/@ember/application/instance.js +18 -3
- package/dist/prod/packages/@ember/array/index.js +3 -3
- package/dist/prod/packages/@ember/array/proxy.js +3 -3
- package/dist/prod/packages/@ember/component/helper.js +305 -1
- package/dist/prod/packages/@ember/component/index.js +3 -3
- package/dist/prod/packages/@ember/controller/index.js +2 -2
- package/dist/prod/packages/@ember/engine/index.js +3 -3
- package/dist/prod/packages/@ember/object/computed.js +2 -2
- package/dist/prod/packages/@ember/object/index.js +4 -4
- package/dist/prod/packages/@ember/object/lib/computed/computed_macros.js +3 -3
- package/dist/prod/packages/@ember/object/lib/computed/reduce_computed_macros.js +1 -1
- package/dist/prod/packages/@ember/object/mixin.js +1 -1
- package/dist/prod/packages/@ember/object/observable.js +3 -3
- package/dist/prod/packages/@ember/object/promise-proxy-mixin.js +2 -2
- package/dist/prod/packages/@ember/renderer/index.js +1 -1
- package/dist/prod/packages/@ember/routing/lib/routing-service.js +0 -1
- package/dist/prod/packages/@ember/routing/lib/utils.js +1 -1
- package/dist/prod/packages/@ember/routing/route.js +4 -4
- package/dist/prod/packages/@ember/routing/router-service.js +0 -1
- package/dist/prod/packages/@ember/routing/router.js +3 -3
- package/dist/prod/packages/@ember/service/index.js +1 -1
- package/dist/prod/packages/@ember/utils/lib/compare.js +5 -2
- package/dist/prod/packages/@glimmer/node/index.js +2 -2
- package/dist/prod/packages/@glimmer/runtime/index.js +3 -3
- package/dist/prod/packages/@glimmer/tracking/index.js +1 -1
- package/dist/prod/packages/@glimmer/validator/index.js +1 -1
- package/dist/prod/packages/ember/version.js +1 -1
- package/dist/prod/packages/router_js/index.js +2 -2
- package/dist/prod/packages/shared-chunks/{alias-Bod6qdNp.js → alias-CHHuE0LE.js} +2 -2
- package/dist/prod/packages/shared-chunks/{api-CQexacBn.js → api-DzOa0Acr.js} +6 -4
- package/dist/prod/packages/shared-chunks/{array-BzReKMeW.js → array-CnXdmzOG.js} +1 -1
- package/dist/prod/packages/shared-chunks/{computed-DtIStxvq.js → computed-BNdMwGhH.js} +1 -6
- package/dist/prod/packages/shared-chunks/{curly-IY06zACp.js → curly-a6DP7r87.js} +4 -5
- package/dist/prod/packages/shared-chunks/curly-brand-B_F79Dep.js +12 -0
- package/dist/prod/packages/shared-chunks/helper-brand-C9_8vvOf.js +12 -0
- package/dist/prod/packages/shared-chunks/{index-CslMfEpb.js → index-CvQQ6l11.js} +548 -1451
- package/dist/prod/packages/shared-chunks/{injected_property-Y-FadDej.js → injected_property-DqQ0XV7k.js} +1 -1
- package/dist/prod/packages/shared-chunks/outlet--lIm3q7t.js +132 -0
- package/dist/prod/packages/shared-chunks/{property_set-BaQJdVfS.js → property_set-CkLe4ht8.js} +1 -1
- package/dist/prod/packages/shared-chunks/{rehydrate-builder-Blt1x9MP.js → rehydrate-builder-n_8RCUj9.js} +1 -1
- package/dist/prod/packages/shared-chunks/{render-Dx7lr1hR.js → render-Bf7GviCY.js} +10 -5
- package/dist/prod/packages/shared-chunks/{serialize-builder-BvAXYHTr.js → serialize-builder-CsG9WHVw.js} +1 -1
- package/dist/prod/packages/shared-chunks/{set_properties-Qxhw4qzw.js → set_properties-Cs3rVemD.js} +2 -2
- package/dist/prod/packages/shared-chunks/setup-registry-kOGgOucf.js +886 -0
- package/dist/prod/packages/shared-chunks/{textarea-DOmZ1x0E.js → textarea-DMmdvgk2.js} +1 -1
- package/dist/prod/packages/shared-chunks/tracked-DvOpYI0o.js +235 -0
- package/dist/prod/packages/shared-chunks/tracked-value-CR6kx-73.js +115 -0
- package/dist/prod/packages/shared-chunks/{unrecognized-url-error-EgNrnFu_.js → unrecognized-url-error-jjQ-FqKB.js} +1 -1
- package/docs/data.json +426 -222
- package/package.json +6 -6
- package/types/stable/@ember/-internals/deprecations/index.d.ts +6 -0
- package/types/stable/@ember/-internals/glimmer/lib/base-renderer.d.ts +150 -0
- package/types/stable/@ember/-internals/glimmer/lib/component-managers/curly-brand.d.ts +10 -0
- package/types/stable/@ember/-internals/glimmer/lib/component-managers/curly.d.ts +3 -2
- package/types/stable/@ember/-internals/glimmer/lib/glimmer-tracking-docs.d.ts +68 -0
- package/types/stable/@ember/-internals/glimmer/lib/helper-brand.d.ts +10 -0
- package/types/stable/@ember/-internals/glimmer/lib/helper.d.ts +4 -6
- package/types/stable/@ember/-internals/glimmer/lib/renderer.d.ts +7 -154
- package/types/stable/@ember/-internals/glimmer/lib/router-resolver.d.ts +17 -0
- package/types/stable/@ember/-internals/metal/lib/tracked.d.ts +53 -6
- package/types/stable/@ember/renderer/index.d.ts +2 -2
- package/types/stable/@glimmer/tracking/index.d.ts +70 -1
- package/types/stable/@glimmer/validator/index.d.ts +1 -0
- package/types/stable/@glimmer/validator/lib/tracked-value.d.ts +58 -0
- package/types/stable/index.d.ts +591 -586
- package/dist/dev/packages/shared-chunks/helper-DIj85_-f.js +0 -326
- package/dist/dev/packages/shared-chunks/setup-registry-9DCmHTFF.js +0 -77
- package/dist/dev/packages/shared-chunks/tracked-DEyf0T_X.js +0 -148
- package/dist/dev/packages/shared-chunks/tracked-data-DgqqRdYO.js +0 -31
- package/dist/prod/packages/shared-chunks/helper-DkXiTBjc.js +0 -310
- package/dist/prod/packages/shared-chunks/setup-registry-U-6VaNQG.js +0 -74
- package/dist/prod/packages/shared-chunks/tracked-B9380JtC.js +0 -132
- package/dist/prod/packages/shared-chunks/tracked-data-CHq42QHb.js +0 -31
package/docs/data.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"name": "The Ember API",
|
|
4
4
|
"description": "The Ember API: a framework for building ambitious web applications",
|
|
5
5
|
"url": "https://emberjs.com/",
|
|
6
|
-
"version": "7.
|
|
6
|
+
"version": "7.3.0-alpha.2"
|
|
7
7
|
},
|
|
8
8
|
"files": {
|
|
9
9
|
"node_modules/rsvp/lib/rsvp/promise/all.js": {
|
|
@@ -202,6 +202,13 @@
|
|
|
202
202
|
},
|
|
203
203
|
"namespaces": {}
|
|
204
204
|
},
|
|
205
|
+
"packages/@ember/-internals/glimmer/lib/component-managers/curly-brand.ts": {
|
|
206
|
+
"name": "packages/@ember/-internals/glimmer/lib/component-managers/curly-brand.ts",
|
|
207
|
+
"modules": {},
|
|
208
|
+
"classes": {},
|
|
209
|
+
"fors": {},
|
|
210
|
+
"namespaces": {}
|
|
211
|
+
},
|
|
205
212
|
"packages/@ember/-internals/glimmer/lib/component-managers/route-template.ts": {
|
|
206
213
|
"name": "packages/@ember/-internals/glimmer/lib/component-managers/route-template.ts",
|
|
207
214
|
"modules": {},
|
|
@@ -526,6 +533,15 @@
|
|
|
526
533
|
"fors": {},
|
|
527
534
|
"namespaces": {}
|
|
528
535
|
},
|
|
536
|
+
"packages/@ember/-internals/glimmer/lib/base-renderer.ts": {
|
|
537
|
+
"name": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
538
|
+
"modules": {},
|
|
539
|
+
"classes": {},
|
|
540
|
+
"fors": {
|
|
541
|
+
"@ember/renderer": 1
|
|
542
|
+
},
|
|
543
|
+
"namespaces": {}
|
|
544
|
+
},
|
|
529
545
|
"packages/@ember/-internals/glimmer/lib/component.ts": {
|
|
530
546
|
"name": "packages/@ember/-internals/glimmer/lib/component.ts",
|
|
531
547
|
"modules": {},
|
|
@@ -544,6 +560,13 @@
|
|
|
544
560
|
},
|
|
545
561
|
"namespaces": {}
|
|
546
562
|
},
|
|
563
|
+
"packages/@ember/-internals/glimmer/lib/helper-brand.ts": {
|
|
564
|
+
"name": "packages/@ember/-internals/glimmer/lib/helper-brand.ts",
|
|
565
|
+
"modules": {},
|
|
566
|
+
"classes": {},
|
|
567
|
+
"fors": {},
|
|
568
|
+
"namespaces": {}
|
|
569
|
+
},
|
|
547
570
|
"packages/@ember/-internals/glimmer/lib/helper.ts": {
|
|
548
571
|
"name": "packages/@ember/-internals/glimmer/lib/helper.ts",
|
|
549
572
|
"modules": {},
|
|
@@ -555,13 +578,11 @@
|
|
|
555
578
|
},
|
|
556
579
|
"namespaces": {}
|
|
557
580
|
},
|
|
558
|
-
"packages/@ember/-internals/glimmer/lib/
|
|
559
|
-
"name": "packages/@ember/-internals/glimmer/lib/
|
|
581
|
+
"packages/@ember/-internals/glimmer/lib/router-resolver.ts": {
|
|
582
|
+
"name": "packages/@ember/-internals/glimmer/lib/router-resolver.ts",
|
|
560
583
|
"modules": {},
|
|
561
584
|
"classes": {},
|
|
562
|
-
"fors": {
|
|
563
|
-
"@ember/renderer": 1
|
|
564
|
-
},
|
|
585
|
+
"fors": {},
|
|
565
586
|
"namespaces": {}
|
|
566
587
|
},
|
|
567
588
|
"packages/@ember/-internals/glimmer/tests/integration/components/render-component-test.ts": {
|
|
@@ -2511,6 +2532,13 @@
|
|
|
2511
2532
|
"fors": {},
|
|
2512
2533
|
"namespaces": {}
|
|
2513
2534
|
},
|
|
2535
|
+
"packages/@glimmer/validator/lib/tracked-value.ts": {
|
|
2536
|
+
"name": "packages/@glimmer/validator/lib/tracked-value.ts",
|
|
2537
|
+
"modules": {},
|
|
2538
|
+
"classes": {},
|
|
2539
|
+
"fors": {},
|
|
2540
|
+
"namespaces": {}
|
|
2541
|
+
},
|
|
2514
2542
|
"packages/@glimmer/validator/lib/tracking.ts": {
|
|
2515
2543
|
"name": "packages/@glimmer/validator/lib/tracking.ts",
|
|
2516
2544
|
"modules": {},
|
|
@@ -2721,40 +2749,40 @@
|
|
|
2721
2749
|
"file": "packages/@ember/-internals/glimmer/lib/utils/string.ts",
|
|
2722
2750
|
"line": 70
|
|
2723
2751
|
},
|
|
2724
|
-
"@
|
|
2725
|
-
"name": "@
|
|
2752
|
+
"@ember/renderer": {
|
|
2753
|
+
"name": "@ember/renderer",
|
|
2726
2754
|
"submodules": {},
|
|
2727
2755
|
"elements": {},
|
|
2728
2756
|
"classes": {
|
|
2729
|
-
"@
|
|
2757
|
+
"@ember/renderer": 1,
|
|
2758
|
+
"Renderer": 1,
|
|
2759
|
+
"BucketCache": 1
|
|
2730
2760
|
},
|
|
2731
2761
|
"fors": {
|
|
2732
|
-
"@
|
|
2762
|
+
"@ember/renderer": 1
|
|
2733
2763
|
},
|
|
2734
2764
|
"namespaces": {},
|
|
2735
2765
|
"tag": "module",
|
|
2736
|
-
"file": "packages/@
|
|
2737
|
-
"line":
|
|
2738
|
-
"description": "In order to tell Ember a value might change, we need to mark it as trackable.\nTrackable values are values that:\n\n- Can change over their component’s lifetime and\n- Should cause Ember to rerender if and when they change\n\nWe can do this by marking the field with the `@tracked` decorator.",
|
|
2766
|
+
"file": "packages/@ember/routing/lib/cache.ts",
|
|
2767
|
+
"line": 1,
|
|
2739
2768
|
"access": "public",
|
|
2740
2769
|
"tagname": ""
|
|
2741
2770
|
},
|
|
2742
|
-
"@
|
|
2743
|
-
"name": "@
|
|
2771
|
+
"@glimmer/tracking": {
|
|
2772
|
+
"name": "@glimmer/tracking",
|
|
2744
2773
|
"submodules": {},
|
|
2745
2774
|
"elements": {},
|
|
2746
2775
|
"classes": {
|
|
2747
|
-
"@
|
|
2748
|
-
"Renderer": 1,
|
|
2749
|
-
"BucketCache": 1
|
|
2776
|
+
"@glimmer/tracking": 1
|
|
2750
2777
|
},
|
|
2751
2778
|
"fors": {
|
|
2752
|
-
"@
|
|
2779
|
+
"@glimmer/tracking": 1
|
|
2753
2780
|
},
|
|
2754
2781
|
"namespaces": {},
|
|
2755
2782
|
"tag": "module",
|
|
2756
|
-
"file": "packages/@
|
|
2757
|
-
"line":
|
|
2783
|
+
"file": "packages/@glimmer/tracking/index.ts",
|
|
2784
|
+
"line": 10,
|
|
2785
|
+
"description": "In order to tell Ember a value might change, we need to mark it as trackable.\nTrackable values are values that:\n\n- Can change over their component’s lifetime and\n- Should cause Ember to rerender if and when they change\n\nWe can do this by marking the field with the `@tracked` decorator.",
|
|
2758
2786
|
"access": "public",
|
|
2759
2787
|
"tagname": ""
|
|
2760
2788
|
},
|
|
@@ -2853,7 +2881,7 @@
|
|
|
2853
2881
|
"namespaces": {},
|
|
2854
2882
|
"tag": "module",
|
|
2855
2883
|
"file": "packages/@ember/utils/lib/compare.ts",
|
|
2856
|
-
"line":
|
|
2884
|
+
"line": 48
|
|
2857
2885
|
},
|
|
2858
2886
|
"@ember/application": {
|
|
2859
2887
|
"name": "@ember/application",
|
|
@@ -3611,6 +3639,17 @@
|
|
|
3611
3639
|
"access": "public",
|
|
3612
3640
|
"tagname": ""
|
|
3613
3641
|
},
|
|
3642
|
+
"@ember/renderer": {
|
|
3643
|
+
"name": "@ember/renderer",
|
|
3644
|
+
"shortname": "@ember/renderer",
|
|
3645
|
+
"classitems": [],
|
|
3646
|
+
"plugins": [],
|
|
3647
|
+
"extensions": [],
|
|
3648
|
+
"plugin_for": [],
|
|
3649
|
+
"extension_for": [],
|
|
3650
|
+
"module": "@ember/renderer",
|
|
3651
|
+
"namespace": ""
|
|
3652
|
+
},
|
|
3614
3653
|
"Component": {
|
|
3615
3654
|
"name": "Component",
|
|
3616
3655
|
"shortname": "Component",
|
|
@@ -3655,7 +3694,7 @@
|
|
|
3655
3694
|
"namespace": "",
|
|
3656
3695
|
"file": "packages/@ember/-internals/glimmer/lib/helper.ts",
|
|
3657
3696
|
"line": 57,
|
|
3658
|
-
"description": "Ember Helpers are functions that can compute values, and are used in templates.\nFor example, this code calls a helper named `format-currency`:\n\n```app/templates/application.gjs\nimport Cost from '../components/cost';\n
|
|
3697
|
+
"description": "Ember Helpers are functions that can compute values, and are used in templates.\nFor example, this code calls a helper named `format-currency`:\n\n```app/templates/application.gjs\nimport Cost from '../components/cost';\n\n<template>\n <Cost @cents={{230}} />\n</template>\n```\n\n```app/components/cost.gjs\nimport formatCurrency from '../helpers/format-currency';\n\n<template>\n <div>{{formatCurrency @cents currency=\"$\"}}</div>\n</template>\n```\n\nAdditionally a helper can be called as a nested helper.\nIn this example, we show the formatted currency value if the `showMoney`\nnamed argument is truthy.\n\n```gjs\nimport formatCurrency from '../helpers/format-currency';\n\n<template>\n {{if @showMoney (formatCurrency @cents currency=\"$\")}}\n</template>\n```\n\nHelpers defined using a class must provide a `compute` function. For example:\n\n```app/helpers/format-currency.js\nimport Helper from '@ember/component/helper';\n\nexport default class extends Helper {\n compute([cents], { currency }) {\n return `${currency}${cents * 0.01}`;\n }\n}\n```\n\nEach time the input to a helper changes, the `compute` function will be\ncalled again.\n\nAs instances, these helpers also have access to the container and will accept\ninjected dependencies.\n\nAdditionally, class helpers can call `recompute` to force a new computation.",
|
|
3659
3698
|
"extends": "CoreObject",
|
|
3660
3699
|
"access": "public",
|
|
3661
3700
|
"tagname": "",
|
|
@@ -3672,17 +3711,6 @@
|
|
|
3672
3711
|
"module": "@ember/component",
|
|
3673
3712
|
"namespace": ""
|
|
3674
3713
|
},
|
|
3675
|
-
"@ember/renderer": {
|
|
3676
|
-
"name": "@ember/renderer",
|
|
3677
|
-
"shortname": "@ember/renderer",
|
|
3678
|
-
"classitems": [],
|
|
3679
|
-
"plugins": [],
|
|
3680
|
-
"extensions": [],
|
|
3681
|
-
"plugin_for": [],
|
|
3682
|
-
"extension_for": [],
|
|
3683
|
-
"module": "@ember/renderer",
|
|
3684
|
-
"namespace": ""
|
|
3685
|
-
},
|
|
3686
3714
|
"Ember": {
|
|
3687
3715
|
"name": "Ember",
|
|
3688
3716
|
"shortname": "Ember",
|
|
@@ -4097,7 +4125,7 @@
|
|
|
4097
4125
|
"module": "ember",
|
|
4098
4126
|
"namespace": "Ember",
|
|
4099
4127
|
"file": "packages/@ember/-internals/runtime/lib/mixins/comparable.ts",
|
|
4100
|
-
"line":
|
|
4128
|
+
"line": 8,
|
|
4101
4129
|
"description": "Implements some standard methods for comparing objects. Add this mixin to\nany class you create that can compare its instances.\n\nYou should implement the `compare()` method.",
|
|
4102
4130
|
"since": "Ember 0.9",
|
|
4103
4131
|
"access": "private",
|
|
@@ -6457,6 +6485,13 @@
|
|
|
6457
6485
|
"class": "EmberENV",
|
|
6458
6486
|
"module": "rsvp"
|
|
6459
6487
|
},
|
|
6488
|
+
{
|
|
6489
|
+
"file": "packages/@ember/-internals/glimmer/lib/component-managers/curly-brand.ts",
|
|
6490
|
+
"line": 1,
|
|
6491
|
+
"description": "The brand for the curly component manager lives in its own module so that\ncode which only needs to *detect* the curly manager (e.g. the resolver)\ndoes not have to import the manager itself (and with it the classic\ncomponent machinery).",
|
|
6492
|
+
"class": "Ember.Templates.helpers",
|
|
6493
|
+
"module": "rsvp"
|
|
6494
|
+
},
|
|
6460
6495
|
{
|
|
6461
6496
|
"file": "packages/@ember/-internals/glimmer/lib/component-managers/route-template.ts",
|
|
6462
6497
|
"line": 113,
|
|
@@ -7168,15 +7203,169 @@
|
|
|
7168
7203
|
{
|
|
7169
7204
|
"file": "packages/@ember/-internals/glimmer/lib/views/outlet.ts",
|
|
7170
7205
|
"line": 114,
|
|
7171
|
-
"class": "
|
|
7206
|
+
"class": "@ember/renderer",
|
|
7172
7207
|
"module": "@ember/template"
|
|
7173
7208
|
},
|
|
7174
7209
|
{
|
|
7175
7210
|
"file": "packages/@ember/-internals/glimmer/lib/views/outlet.ts",
|
|
7176
7211
|
"line": 122,
|
|
7177
|
-
"class": "
|
|
7212
|
+
"class": "@ember/renderer",
|
|
7213
|
+
"module": "@ember/template"
|
|
7214
|
+
},
|
|
7215
|
+
{
|
|
7216
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7217
|
+
"line": 68,
|
|
7218
|
+
"description": "The interface the `RendererState` needs from a render root. The base\nrenderer only ever creates `ComponentRootState`s; the classic renderer\n(`./renderer`) adds `ClassicRootState` for outlet/classic-component roots.",
|
|
7219
|
+
"class": "@ember/renderer",
|
|
7178
7220
|
"module": "@ember/template"
|
|
7179
7221
|
},
|
|
7222
|
+
{
|
|
7223
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7224
|
+
"line": 413,
|
|
7225
|
+
"description": "Destroys the render tree and removes all rendered content from the element rendered into",
|
|
7226
|
+
"class": "@ember/renderer",
|
|
7227
|
+
"module": "@ember/renderer"
|
|
7228
|
+
},
|
|
7229
|
+
{
|
|
7230
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7231
|
+
"line": 421,
|
|
7232
|
+
"description": "The GlimmerRenderResult from the last render. Used to get positional\ninformation (firstNode) when a re-render replaces the content, so\nthat the new content is placed at the same DOM position.",
|
|
7233
|
+
"class": "@ember/renderer",
|
|
7234
|
+
"module": "@ember/renderer"
|
|
7235
|
+
},
|
|
7236
|
+
{
|
|
7237
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7238
|
+
"line": 437,
|
|
7239
|
+
"description": "Render a component into a DOM element.",
|
|
7240
|
+
"itemtype": "method",
|
|
7241
|
+
"name": "renderComponent",
|
|
7242
|
+
"static": 1,
|
|
7243
|
+
"params": [
|
|
7244
|
+
{
|
|
7245
|
+
"name": "component",
|
|
7246
|
+
"description": "The component to render.",
|
|
7247
|
+
"type": "Object"
|
|
7248
|
+
},
|
|
7249
|
+
{
|
|
7250
|
+
"name": "options",
|
|
7251
|
+
"description": "",
|
|
7252
|
+
"type": "Object",
|
|
7253
|
+
"props": [
|
|
7254
|
+
{
|
|
7255
|
+
"name": "into",
|
|
7256
|
+
"description": "Where to render the component in to.",
|
|
7257
|
+
"type": "Element"
|
|
7258
|
+
},
|
|
7259
|
+
{
|
|
7260
|
+
"name": "owner",
|
|
7261
|
+
"description": "Optionally specify the owner to use. This will be used for injections, and overall cleanup.",
|
|
7262
|
+
"type": "Object",
|
|
7263
|
+
"optional": true
|
|
7264
|
+
},
|
|
7265
|
+
{
|
|
7266
|
+
"name": "env",
|
|
7267
|
+
"description": "Optional renderer configuration",
|
|
7268
|
+
"type": "Object",
|
|
7269
|
+
"optional": true
|
|
7270
|
+
},
|
|
7271
|
+
{
|
|
7272
|
+
"name": "args",
|
|
7273
|
+
"description": "Optionally pass args in to the component. These may be reactive as long as it is an object or object-like",
|
|
7274
|
+
"type": "Object",
|
|
7275
|
+
"optional": true
|
|
7276
|
+
}
|
|
7277
|
+
]
|
|
7278
|
+
}
|
|
7279
|
+
],
|
|
7280
|
+
"access": "public",
|
|
7281
|
+
"tagname": "",
|
|
7282
|
+
"class": "@ember/renderer",
|
|
7283
|
+
"module": "@ember/renderer"
|
|
7284
|
+
},
|
|
7285
|
+
{
|
|
7286
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7287
|
+
"line": 452,
|
|
7288
|
+
"description": "The component definition to render.\n\nAny component that has had its manager registered is valid.\nFor the component-types that ship with ember, manager registration\ndoes not need to be worried about.",
|
|
7289
|
+
"class": "@ember/renderer",
|
|
7290
|
+
"module": "@ember/renderer"
|
|
7291
|
+
},
|
|
7292
|
+
{
|
|
7293
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7294
|
+
"line": 466,
|
|
7295
|
+
"description": "The element to render the component in to.",
|
|
7296
|
+
"class": "@ember/renderer",
|
|
7297
|
+
"module": "@ember/renderer"
|
|
7298
|
+
},
|
|
7299
|
+
{
|
|
7300
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7301
|
+
"line": 471,
|
|
7302
|
+
"description": "Optional owner. Defaults to `{}`, can be any object, but will need to implement the [Owner](https://api.emberjs.com/ember/release/classes/Owner) API for components within this render tree to access services.",
|
|
7303
|
+
"class": "@ember/renderer",
|
|
7304
|
+
"module": "@ember/renderer"
|
|
7305
|
+
},
|
|
7306
|
+
{
|
|
7307
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7308
|
+
"line": 475,
|
|
7309
|
+
"description": "Optionally configure the rendering environment",
|
|
7310
|
+
"class": "@ember/renderer",
|
|
7311
|
+
"module": "@ember/renderer"
|
|
7312
|
+
},
|
|
7313
|
+
{
|
|
7314
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7315
|
+
"line": 479,
|
|
7316
|
+
"description": "When false, modifiers will not run.",
|
|
7317
|
+
"class": "@ember/renderer",
|
|
7318
|
+
"module": "@ember/renderer"
|
|
7319
|
+
},
|
|
7320
|
+
{
|
|
7321
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7322
|
+
"line": 483,
|
|
7323
|
+
"description": "All other options are forwarded to the underlying renderer.\n(its API is currently private and out of scope for this RFC,\n so passing additional things here is also considered private API)",
|
|
7324
|
+
"class": "@ember/renderer",
|
|
7325
|
+
"module": "@ember/renderer"
|
|
7326
|
+
},
|
|
7327
|
+
{
|
|
7328
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7329
|
+
"line": 491,
|
|
7330
|
+
"description": "These args get passed to the rendered component\n\nIf your args are reactive, re-rendering will happen automatically.",
|
|
7331
|
+
"class": "@ember/renderer",
|
|
7332
|
+
"module": "@ember/renderer"
|
|
7333
|
+
},
|
|
7334
|
+
{
|
|
7335
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7336
|
+
"line": 500,
|
|
7337
|
+
"description": "SAFETY: we should figure out what we need out of a `document` and narrow the API.\n this exercise should also end up beginning to define what we need for CLI rendering (or to other outputs)",
|
|
7338
|
+
"class": "@ember/renderer",
|
|
7339
|
+
"module": "@ember/renderer"
|
|
7340
|
+
},
|
|
7341
|
+
{
|
|
7342
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7343
|
+
"line": 521,
|
|
7344
|
+
"description": "Replace all contents, if we've rendered multiple times.\n\nhttps://github.com/emberjs/rfcs/pull/1099/files#diff-2b962105b9083ca84579cdc957f27f49407440f3c5078083fa369ec18cc46da8R365\n\nWe could later add an option to not do this behavior\n\nNOTE: destruction is async",
|
|
7345
|
+
"class": "@ember/renderer",
|
|
7346
|
+
"module": "@ember/renderer"
|
|
7347
|
+
},
|
|
7348
|
+
{
|
|
7349
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7350
|
+
"line": 532,
|
|
7351
|
+
"description": "We can only replace the inner HTML the first time.\nBecause destruction is async, it won't be safe to\ndo this again, and we'll have to rely on the above destroy.",
|
|
7352
|
+
"class": "@ember/renderer",
|
|
7353
|
+
"module": "@ember/renderer"
|
|
7354
|
+
},
|
|
7355
|
+
{
|
|
7356
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7357
|
+
"line": 541,
|
|
7358
|
+
"description": "If there's an existing render result with valid bounds, use its\nfirstNode as the nextSibling so that new content is inserted at\nthe same DOM position. This ensures stable ordering when multiple\nrenderComponent calls target the same element and one is re-invoked\n(e.g., due to tracked dependency changes).\n\nThe old content's DOM nodes are still present (destruction is async),\nso firstNode() is a valid position reference. The new content is placed\nBEFORE the old content. When the old content is eventually destroyed\n(async clear of bounds), the new content remains in the correct position.",
|
|
7359
|
+
"class": "@ember/renderer",
|
|
7360
|
+
"module": "@ember/renderer"
|
|
7361
|
+
},
|
|
7362
|
+
{
|
|
7363
|
+
"file": "packages/@ember/-internals/glimmer/lib/base-renderer.ts",
|
|
7364
|
+
"line": 609,
|
|
7365
|
+
"description": "SAFETY: are there consequences for being looser with *this* owner?\n the public API for `owner` is kinda `Partial<InternalOwner>`\n aka: implement only what you need.\n But for actual ember apps, you *need* to implement everything\n an app needs (which will actually change and become less over time)",
|
|
7366
|
+
"class": "@ember/renderer",
|
|
7367
|
+
"module": "@ember/renderer"
|
|
7368
|
+
},
|
|
7180
7369
|
{
|
|
7181
7370
|
"file": "packages/@ember/-internals/glimmer/lib/component.ts",
|
|
7182
7371
|
"line": 41,
|
|
@@ -7198,7 +7387,7 @@
|
|
|
7198
7387
|
}
|
|
7199
7388
|
],
|
|
7200
7389
|
"class": "Component",
|
|
7201
|
-
"module": "@ember/
|
|
7390
|
+
"module": "@ember/renderer"
|
|
7202
7391
|
},
|
|
7203
7392
|
{
|
|
7204
7393
|
"file": "packages/@ember/-internals/glimmer/lib/component.ts",
|
|
@@ -7714,7 +7903,7 @@
|
|
|
7714
7903
|
{
|
|
7715
7904
|
"file": "packages/@ember/-internals/glimmer/lib/glimmer-tracking-docs.ts",
|
|
7716
7905
|
"line": 22,
|
|
7717
|
-
"description": "Marks a property as tracked. By default, values that are rendered in Ember app\ntemplates are _static_, meaning that updates to them won't cause the\napplication to rerender. Marking a property as tracked means that when that\nproperty changes, any templates that used that property, directly or\nindirectly, will rerender. For instance, consider this component:\n\n```gjs\nimport Component from '@glimmer/component';\nimport { tracked } from '@glimmer/tracking';\nimport { action } from '@ember/object';\n\nexport default class CounterComponent extends Component {\n @tracked count = 0;\n\n get timesTen() {\n return this.count * 10;\n }\n\n @action\n plusOne() {\n this.count += 1;\n }\n \n <template>\n <div>Count: {{this.count}}</div>\n <div>Times Ten: {{this.timesTen}}</div>\n <div>\n <button {{on \"click\" this.plusOne}}>\n Plus One\n </button>\n </div>\n </template>\n}\n```\n\nBoth the `{{this.count}}` and the `{{this.timesTen}}` properties in the\ntemplate will update whenever the button is clicked. Any tracked properties\nthat are used in any way to calculate a value that is used in the template\nwill cause a rerender when updated - this includes through method calls and\nother means:\n\n```gjs\nimport Component from '@glimmer/component';\nimport { tracked } from '@glimmer/tracking';\n\nclass Entry {\n @tracked name;\n @tracked phoneNumber;\n\n constructor(name, phoneNumber) {\n this.name = name;\n this.phoneNumber = phoneNumber;\n }\n}\n\nexport default class PhoneBookComponent extends Component {\n entries = [\n new Entry('Pizza Palace', 5551234),\n new Entry('1st Street Cleaners', 5554321),\n new Entry('Plants R Us', 5552468),\n ];\n\n // Any usage of this property will update whenever any of the names in the\n // entries arrays are updated\n get names() {\n return this.entries.map(e => e.name);\n }\n\n // Any usage of this property will update whenever any of the numbers in the\n // entries arrays are updated\n get numbers() {\n return this.getFormattedNumbers();\n }\n\n getFormattedNumbers() {\n return this.entries\n .map(e => e.phoneNumber)\n .map(number => {\n let numberString = '' + number;\n\n return numberString.slice(0, 3) + '-' + numberString.slice(3);\n });\n }\n}\n```\n\nIt's important to note that setting tracked properties will always trigger an\nupdate, even if the property is set to the same value as it was before.\n\n```js\nlet entry = new Entry('Pizza Palace', 5551234);\n\n// if entry was used when rendering, this would cause a rerender, even though\n// the name is being set to the same value as it was before\nentry.name = entry.name;\n```\n\n`tracked` can also be used with the classic Ember object model in a similar\nmanner to classic computed properties:\n\n```javascript\nimport EmberObject from '@ember/object';\nimport { tracked } from '@glimmer/tracking';\n\nconst Entry = EmberObject.extend({\n name: tracked(),\n phoneNumber: tracked()\n});\n```\n\nOften this is unnecessary, but to ensure robust auto-tracking behavior it is\nadvisable to mark tracked state appropriately wherever possible.\n\nThis form of `tracked` also accepts an optional configuration object\ncontaining either an initial `value` or an `initializer` function (but not\nboth).\n\n```javascript\nimport EmberObject from '@ember/object';\nimport { tracked } from '@glimmer/tracking';\n\nconst Entry = EmberObject.extend({\n name: tracked({ value: 'Zoey' }),\n favoriteSongs: tracked({\n initializer: () => ['Raspberry Beret', 'Time After Time']\n })\n});\n```",
|
|
7906
|
+
"description": "Marks a property as tracked. By default, values that are rendered in Ember app\ntemplates are _static_, meaning that updates to them won't cause the\napplication to rerender. Marking a property as tracked means that when that\nproperty changes, any templates that used that property, directly or\nindirectly, will rerender. For instance, consider this component:\n\n```gjs\nimport Component from '@glimmer/component';\nimport { tracked } from '@glimmer/tracking';\nimport { action } from '@ember/object';\n\nexport default class CounterComponent extends Component {\n @tracked count = 0;\n\n get timesTen() {\n return this.count * 10;\n }\n\n @action\n plusOne() {\n this.count += 1;\n }\n \n <template>\n <div>Count: {{this.count}}</div>\n <div>Times Ten: {{this.timesTen}}</div>\n <div>\n <button {{on \"click\" this.plusOne}}>\n Plus One\n </button>\n </div>\n </template>\n}\n```\n\nBoth the `{{this.count}}` and the `{{this.timesTen}}` properties in the\ntemplate will update whenever the button is clicked. Any tracked properties\nthat are used in any way to calculate a value that is used in the template\nwill cause a rerender when updated - this includes through method calls and\nother means:\n\n```gjs\nimport Component from '@glimmer/component';\nimport { tracked } from '@glimmer/tracking';\n\nclass Entry {\n @tracked name;\n @tracked phoneNumber;\n\n constructor(name, phoneNumber) {\n this.name = name;\n this.phoneNumber = phoneNumber;\n }\n}\n\nexport default class PhoneBookComponent extends Component {\n entries = [\n new Entry('Pizza Palace', 5551234),\n new Entry('1st Street Cleaners', 5554321),\n new Entry('Plants R Us', 5552468),\n ];\n\n // Any usage of this property will update whenever any of the names in the\n // entries arrays are updated\n get names() {\n return this.entries.map(e => e.name);\n }\n\n // Any usage of this property will update whenever any of the numbers in the\n // entries arrays are updated\n get numbers() {\n return this.getFormattedNumbers();\n }\n\n getFormattedNumbers() {\n return this.entries\n .map(e => e.phoneNumber)\n .map(number => {\n let numberString = '' + number;\n\n return numberString.slice(0, 3) + '-' + numberString.slice(3);\n });\n }\n}\n```\n\nIt's important to note that setting tracked properties will always trigger an\nupdate, even if the property is set to the same value as it was before.\n\n```js\nlet entry = new Entry('Pizza Palace', 5551234);\n\n// if entry was used when rendering, this would cause a rerender, even though\n// the name is being set to the same value as it was before\nentry.name = entry.name;\n```\n\n`tracked` can also be used with the classic Ember object model in a similar\nmanner to classic computed properties:\n\n```javascript\nimport EmberObject from '@ember/object';\nimport { tracked } from '@glimmer/tracking';\n\nconst Entry = EmberObject.extend({\n name: tracked(),\n phoneNumber: tracked()\n});\n```\n\nOften this is unnecessary, but to ensure robust auto-tracking behavior it is\nadvisable to mark tracked state appropriately wherever possible.\n\nThis form of `tracked` also accepts an optional configuration object\ncontaining either an initial `value` or an `initializer` function (but not\nboth).\n\n```javascript\nimport EmberObject from '@ember/object';\nimport { tracked } from '@glimmer/tracking';\n\nconst Entry = EmberObject.extend({\n name: tracked({ value: 'Zoey' }),\n favoriteSongs: tracked({\n initializer: () => ['Raspberry Beret', 'Time After Time']\n })\n});\n```\n\nCalling `tracked` with an initial value creates a standalone reactive\nvalue, usable outside of classes:\n\n```js\nimport { tracked } from '@glimmer/tracking';\n\nconst count = tracked(0);\n\ncount.value; // read the value, entangling with any tracking context\ncount.value = 1; // write the value, notifying consumers\ncount.get(); // function shorthand for reading\ncount.set(2); // function shorthand for writing\ncount.update((n) => n + 1); // write based on the current value, without entangling\ncount.freeze(); // prevent all future writes\n```\n\nReading `value` in a template (or in a getter used by a template) will\nrerender just like a `@tracked` property:\n\n```gjs\nimport { tracked } from '@glimmer/tracking';\nimport { on } from '@ember/modifier';\n\nconst count = tracked(0);\nconst increment = () => count.value++;\n\n<template>\n Count is: {{count.value}}\n\n <button {{on \"click\" increment}}>add one</button>\n</template>\n```\n\nThis form accepts an options object containing an `equals` function, which\ndecides whether a written value should notify consumers (it defaults to\n`Object.is`), and a `description` used for debugging:\n\n```js\nconst count = tracked(0, { equals: (a, b) => a === b });\n\ncount.value = 0; // does not notify consumers, the value did not change\n```\n\nNote: when `tracked` is called with a single plain object whose keys are all\ndrawn from `value`, `initializer`, `equals`, and `description`, it is treated\nas the configuration object for a decorator (or classic-class field), not as a\nstandalone value wrapping that object. To create a standalone reactive value\naround such an object, pass it as an initial value and include a (possibly\nempty) options argument: `tracked({ value: 5 }, {})`.\n\nThe `@tracked` decorator accepts the same options. By default, setting a\n`@tracked` property always notifies consumers, even when setting the\nproperty to the same value; passing `equals` opts in to equality-based\nnotification instead:\n\n```js\nimport { tracked } from '@glimmer/tracking';\n\nclass Counter {\n @tracked({ equals: (a, b) => a === b }) count = 0;\n\n noop = () => {\n // does not notify consumers, the value did not change\n this.count = this.count;\n };\n}\n```",
|
|
7718
7907
|
"itemtype": "method",
|
|
7719
7908
|
"name": "tracked",
|
|
7720
7909
|
"static": 1,
|
|
@@ -7725,7 +7914,7 @@
|
|
|
7725
7914
|
},
|
|
7726
7915
|
{
|
|
7727
7916
|
"file": "packages/@ember/-internals/glimmer/lib/glimmer-tracking-docs.ts",
|
|
7728
|
-
"line":
|
|
7917
|
+
"line": 226,
|
|
7729
7918
|
"description": "Gives the getter a caching behavior. The return value of the getter\nwill be cached until any of the properties it is entangled with\nare invalidated. This is useful when a getter is expensive and\nused very often.\n\nFor instance, in this `GuestList` class, we have the `sortedGuests`\ngetter that sorts the guests alphabetically:\n\n```javascript\n import { tracked } from '@glimmer/tracking';\n\n class GuestList {\n @tracked guests = ['Zoey', 'Tomster'];\n\n get sortedGuests() {\n return this.guests.slice().sort()\n }\n }\n```\n\nEvery time `sortedGuests` is accessed, a new array will be created and sorted,\nbecause JavaScript getters do not cache by default. When the guest list\nis small, like the one in the example, this is not a problem. However, if\nthe guest list were to grow very large, it would mean that we would be doing\na large amount of work each time we accessed `sortedGuests`. With `@cached`,\nwe can cache the value instead:\n\n```javascript\n import { tracked, cached } from '@glimmer/tracking';\n\n class GuestList {\n @tracked guests = ['Zoey', 'Tomster'];\n\n @cached\n get sortedGuests() {\n return this.guests.slice().sort()\n }\n }\n```\n\nNow the `sortedGuests` getter will be cached based on autotracking.\nIt will only rerun and create a new sorted array when the guests tracked\nproperty is updated.\n\n\n### Tradeoffs\n\nOveruse is discouraged.\n\nIn general, you should avoid using `@cached` unless you have confirmed that\nthe getter you are decorating is computationally expensive, since `@cached`\nadds a small amount of overhead to the getter.\nWhile the individual costs are small, a systematic use of the `@cached`\ndecorator can add up to a large impact overall in your app.\nMany getters and tracked properties are only accessed once during rendering,\nand then never rerendered, so adding `@cached` when unnecessary can\nnegatively impact performance.\n\nAlso, `@cached` may rerun even if the values themselves have not changed,\nsince tracked properties will always invalidate.\nFor example updating an integer value from `5` to an other `5` will trigger\na rerun of the cached properties building from this integer.\n\nAvoiding a cache invalidation in this case is not something that can\nbe achieved on the `@cached` decorator itself, but rather when updating\nthe underlying tracked values, by applying some diff checking mechanisms:\n\n```javascript\nif (nextValue !== this.trackedProp) {\n this.trackedProp = nextValue;\n}\n```\n\nHere equal values won't update the property, therefore not triggering\nthe subsequent cache invalidations of the `@cached` properties who were\nusing this `trackedProp`.\n\nRemember that setting tracked data should only be done during initialization,\nor as the result of a user action. Setting tracked data during render\n(such as in a getter), is not supported.",
|
|
7730
7919
|
"itemtype": "method",
|
|
7731
7920
|
"name": "cached",
|
|
@@ -7735,6 +7924,13 @@
|
|
|
7735
7924
|
"class": "@glimmer/tracking",
|
|
7736
7925
|
"module": "@glimmer/tracking"
|
|
7737
7926
|
},
|
|
7927
|
+
{
|
|
7928
|
+
"file": "packages/@ember/-internals/glimmer/lib/helper-brand.ts",
|
|
7929
|
+
"line": 1,
|
|
7930
|
+
"description": "The brand for classic (class-based) helpers lives in its own module so that\ncode which only needs to *detect* classic helpers (e.g. the resolver) does\nnot have to import the classic `Helper` base class (and with it the classic\nobject model: `EmberObject`, `Mixin`, meta, etc.).",
|
|
7931
|
+
"class": "Helper",
|
|
7932
|
+
"module": "@glimmer/tracking"
|
|
7933
|
+
},
|
|
7738
7934
|
{
|
|
7739
7935
|
"file": "packages/@ember/-internals/glimmer/lib/helper.ts",
|
|
7740
7936
|
"line": 117,
|
|
@@ -7779,7 +7975,7 @@
|
|
|
7779
7975
|
},
|
|
7780
7976
|
{
|
|
7781
7977
|
"file": "packages/@ember/-internals/glimmer/lib/helper.ts",
|
|
7782
|
-
"line":
|
|
7978
|
+
"line": 319,
|
|
7783
7979
|
"description": "The type of a function-based helper.",
|
|
7784
7980
|
"note": "This is *not* user-constructible: it is exported only so that the type\n returned by the `helper` function can be named (and indeed can be exported\n like `export default helper(...)` safely).",
|
|
7785
7981
|
"class": "Helper",
|
|
@@ -7787,7 +7983,7 @@
|
|
|
7787
7983
|
},
|
|
7788
7984
|
{
|
|
7789
7985
|
"file": "packages/@ember/-internals/glimmer/lib/helper.ts",
|
|
7790
|
-
"line":
|
|
7986
|
+
"line": 350,
|
|
7791
7987
|
"description": "In many cases it is not necessary to use the full `Helper` class.\nThe `helper` method create pure-function helpers without instances.\nFor example:\n\n```app/helpers/format-currency.js\nimport { helper } from '@ember/component/helper';\n\nexport default helper(function([cents], {currency}) {\n return `${currency}${cents * 0.01}`;\n});\n```",
|
|
7792
7988
|
"static": 1,
|
|
7793
7989
|
"params": [
|
|
@@ -7806,158 +8002,18 @@
|
|
|
7806
8002
|
"module": "@ember/component"
|
|
7807
8003
|
},
|
|
7808
8004
|
{
|
|
7809
|
-
"file": "packages/@ember/-internals/glimmer/lib/
|
|
7810
|
-
"line":
|
|
7811
|
-
"description": "
|
|
7812
|
-
"class": "
|
|
7813
|
-
"module": "@ember/
|
|
7814
|
-
},
|
|
7815
|
-
{
|
|
7816
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7817
|
-
"line": 560,
|
|
7818
|
-
"description": "The GlimmerRenderResult from the last render. Used to get positional\ninformation (firstNode) when a re-render replaces the content, so\nthat the new content is placed at the same DOM position.",
|
|
7819
|
-
"class": "@ember/renderer",
|
|
7820
|
-
"module": "@ember/renderer"
|
|
7821
|
-
},
|
|
7822
|
-
{
|
|
7823
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7824
|
-
"line": 576,
|
|
7825
|
-
"description": "Render a component into a DOM element.",
|
|
7826
|
-
"itemtype": "method",
|
|
7827
|
-
"name": "renderComponent",
|
|
7828
|
-
"static": 1,
|
|
7829
|
-
"params": [
|
|
7830
|
-
{
|
|
7831
|
-
"name": "component",
|
|
7832
|
-
"description": "The component to render.",
|
|
7833
|
-
"type": "Object"
|
|
7834
|
-
},
|
|
7835
|
-
{
|
|
7836
|
-
"name": "options",
|
|
7837
|
-
"description": "",
|
|
7838
|
-
"type": "Object",
|
|
7839
|
-
"props": [
|
|
7840
|
-
{
|
|
7841
|
-
"name": "into",
|
|
7842
|
-
"description": "Where to render the component in to.",
|
|
7843
|
-
"type": "Element"
|
|
7844
|
-
},
|
|
7845
|
-
{
|
|
7846
|
-
"name": "owner",
|
|
7847
|
-
"description": "Optionally specify the owner to use. This will be used for injections, and overall cleanup.",
|
|
7848
|
-
"type": "Object",
|
|
7849
|
-
"optional": true
|
|
7850
|
-
},
|
|
7851
|
-
{
|
|
7852
|
-
"name": "env",
|
|
7853
|
-
"description": "Optional renderer configuration",
|
|
7854
|
-
"type": "Object",
|
|
7855
|
-
"optional": true
|
|
7856
|
-
},
|
|
7857
|
-
{
|
|
7858
|
-
"name": "args",
|
|
7859
|
-
"description": "Optionally pass args in to the component. These may be reactive as long as it is an object or object-like",
|
|
7860
|
-
"type": "Object",
|
|
7861
|
-
"optional": true
|
|
7862
|
-
}
|
|
7863
|
-
]
|
|
7864
|
-
}
|
|
7865
|
-
],
|
|
7866
|
-
"access": "public",
|
|
7867
|
-
"tagname": "",
|
|
7868
|
-
"class": "@ember/renderer",
|
|
7869
|
-
"module": "@ember/renderer"
|
|
7870
|
-
},
|
|
7871
|
-
{
|
|
7872
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7873
|
-
"line": 591,
|
|
7874
|
-
"description": "The component definition to render.\n\nAny component that has had its manager registered is valid.\nFor the component-types that ship with ember, manager registration\ndoes not need to be worried about.",
|
|
7875
|
-
"class": "@ember/renderer",
|
|
7876
|
-
"module": "@ember/renderer"
|
|
7877
|
-
},
|
|
7878
|
-
{
|
|
7879
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7880
|
-
"line": 605,
|
|
7881
|
-
"description": "The element to render the component in to.",
|
|
7882
|
-
"class": "@ember/renderer",
|
|
7883
|
-
"module": "@ember/renderer"
|
|
7884
|
-
},
|
|
7885
|
-
{
|
|
7886
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7887
|
-
"line": 610,
|
|
7888
|
-
"description": "Optional owner. Defaults to `{}`, can be any object, but will need to implement the [Owner](https://api.emberjs.com/ember/release/classes/Owner) API for components within this render tree to access services.",
|
|
7889
|
-
"class": "@ember/renderer",
|
|
7890
|
-
"module": "@ember/renderer"
|
|
7891
|
-
},
|
|
7892
|
-
{
|
|
7893
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7894
|
-
"line": 614,
|
|
7895
|
-
"description": "Optionally configure the rendering environment",
|
|
7896
|
-
"class": "@ember/renderer",
|
|
7897
|
-
"module": "@ember/renderer"
|
|
7898
|
-
},
|
|
7899
|
-
{
|
|
7900
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7901
|
-
"line": 618,
|
|
7902
|
-
"description": "When false, modifiers will not run.",
|
|
7903
|
-
"class": "@ember/renderer",
|
|
7904
|
-
"module": "@ember/renderer"
|
|
7905
|
-
},
|
|
7906
|
-
{
|
|
7907
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7908
|
-
"line": 622,
|
|
7909
|
-
"description": "All other options are forwarded to the underlying renderer.\n(its API is currently private and out of scope for this RFC,\n so passing additional things here is also considered private API)",
|
|
7910
|
-
"class": "@ember/renderer",
|
|
7911
|
-
"module": "@ember/renderer"
|
|
7912
|
-
},
|
|
7913
|
-
{
|
|
7914
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7915
|
-
"line": 630,
|
|
7916
|
-
"description": "These args get passed to the rendered component\n\nIf your args are reactive, re-rendering will happen automatically.",
|
|
7917
|
-
"class": "@ember/renderer",
|
|
7918
|
-
"module": "@ember/renderer"
|
|
7919
|
-
},
|
|
7920
|
-
{
|
|
7921
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7922
|
-
"line": 639,
|
|
7923
|
-
"description": "SAFETY: we should figure out what we need out of a `document` and narrow the API.\n this exercise should also end up beginning to define what we need for CLI rendering (or to other outputs)",
|
|
7924
|
-
"class": "@ember/renderer",
|
|
7925
|
-
"module": "@ember/renderer"
|
|
7926
|
-
},
|
|
7927
|
-
{
|
|
7928
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7929
|
-
"line": 660,
|
|
7930
|
-
"description": "Replace all contents, if we've rendered multiple times.\n\nhttps://github.com/emberjs/rfcs/pull/1099/files#diff-2b962105b9083ca84579cdc957f27f49407440f3c5078083fa369ec18cc46da8R365\n\nWe could later add an option to not do this behavior\n\nNOTE: destruction is async",
|
|
7931
|
-
"class": "@ember/renderer",
|
|
7932
|
-
"module": "@ember/renderer"
|
|
7933
|
-
},
|
|
7934
|
-
{
|
|
7935
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7936
|
-
"line": 671,
|
|
7937
|
-
"description": "We can only replace the inner HTML the first time.\nBecause destruction is async, it won't be safe to\ndo this again, and we'll have to rely on the above destroy.",
|
|
7938
|
-
"class": "@ember/renderer",
|
|
7939
|
-
"module": "@ember/renderer"
|
|
7940
|
-
},
|
|
7941
|
-
{
|
|
7942
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7943
|
-
"line": 680,
|
|
7944
|
-
"description": "If there's an existing render result with valid bounds, use its\nfirstNode as the nextSibling so that new content is inserted at\nthe same DOM position. This ensures stable ordering when multiple\nrenderComponent calls target the same element and one is re-invoked\n(e.g., due to tracked dependency changes).\n\nThe old content's DOM nodes are still present (destruction is async),\nso firstNode() is a valid position reference. The new content is placed\nBEFORE the old content. When the old content is eventually destroyed\n(async clear of bounds), the new content remains in the correct position.",
|
|
7945
|
-
"class": "@ember/renderer",
|
|
7946
|
-
"module": "@ember/renderer"
|
|
7947
|
-
},
|
|
7948
|
-
{
|
|
7949
|
-
"file": "packages/@ember/-internals/glimmer/lib/renderer.ts",
|
|
7950
|
-
"line": 748,
|
|
7951
|
-
"description": "SAFETY: are there consequences for being looser with *this* owner?\n the public API for `owner` is kinda `Partial<InternalOwner>`\n aka: implement only what you need.\n But for actual ember apps, you *need* to implement everything\n an app needs (which will actually change and become less over time)",
|
|
7952
|
-
"class": "@ember/renderer",
|
|
7953
|
-
"module": "@ember/renderer"
|
|
8005
|
+
"file": "packages/@ember/-internals/glimmer/lib/router-resolver.ts",
|
|
8006
|
+
"line": 13,
|
|
8007
|
+
"description": "The resolver used by the classic application `Renderer`. It extends the\nshared `ResolverImpl` with the keywords that require the router and engine\ninfrastructure (`{{outlet}}` and `{{mount}}`). Keeping these out of the\nbase resolver means renderers that have no router (e.g. `renderComponent`)\ndo not pull the outlet/engine machinery into the build.",
|
|
8008
|
+
"class": "Ember.Templates.helpers",
|
|
8009
|
+
"module": "@ember/component"
|
|
7954
8010
|
},
|
|
7955
8011
|
{
|
|
7956
8012
|
"file": "packages/@ember/-internals/glimmer/tests/integration/components/render-component-test.ts",
|
|
7957
8013
|
"line": 445,
|
|
7958
8014
|
"description": "Test skipped because when an error occurs,\nwe mess up the cache used by renderComponent.",
|
|
7959
8015
|
"class": "Ember.Templates.helpers",
|
|
7960
|
-
"module": "@ember/
|
|
8016
|
+
"module": "@ember/component"
|
|
7961
8017
|
},
|
|
7962
8018
|
{
|
|
7963
8019
|
"file": "packages/@ember/-internals/glimmer/tests/integration/components/render-component-test.ts",
|
|
@@ -7969,28 +8025,28 @@
|
|
|
7969
8025
|
"due\n to being destroyed."
|
|
7970
8026
|
],
|
|
7971
8027
|
"class": "Ember.Templates.helpers",
|
|
7972
|
-
"module": "@ember/
|
|
8028
|
+
"module": "@ember/component"
|
|
7973
8029
|
},
|
|
7974
8030
|
{
|
|
7975
8031
|
"file": "packages/@ember/-internals/glimmer/tests/integration/components/render-component-test.ts",
|
|
7976
8032
|
"line": 759,
|
|
7977
8033
|
"description": "NOTE: subsequent renders to the same element are prepended to the element's children",
|
|
7978
8034
|
"class": "Ember.Templates.helpers",
|
|
7979
|
-
"module": "@ember/
|
|
8035
|
+
"module": "@ember/component"
|
|
7980
8036
|
},
|
|
7981
8037
|
{
|
|
7982
8038
|
"file": "packages/@ember/-internals/glimmer/tests/integration/components/render-component-test.ts",
|
|
7983
8039
|
"line": 828,
|
|
7984
8040
|
"description": "ERROR in conflict with the NOTE on this test.\nthe elementns flip locations... which is kinda bonkers",
|
|
7985
8041
|
"class": "Ember.Templates.helpers",
|
|
7986
|
-
"module": "@ember/
|
|
8042
|
+
"module": "@ember/component"
|
|
7987
8043
|
},
|
|
7988
8044
|
{
|
|
7989
8045
|
"file": "packages/@ember/-internals/glimmer/tests/integration/components/render-component-test.ts",
|
|
7990
8046
|
"line": 925,
|
|
7991
8047
|
"description": "We need to pass a scope so that we get a strict-mode component.",
|
|
7992
8048
|
"class": "Ember.Templates.helpers",
|
|
7993
|
-
"module": "@ember/
|
|
8049
|
+
"module": "@ember/component"
|
|
7994
8050
|
},
|
|
7995
8051
|
{
|
|
7996
8052
|
"file": "packages/@ember/-internals/glimmer/tests/integration/components/runtime-template-compiler-implicit-test.ts",
|
|
@@ -8003,7 +8059,7 @@
|
|
|
8003
8059
|
}
|
|
8004
8060
|
],
|
|
8005
8061
|
"class": "Ember.Templates.helpers",
|
|
8006
|
-
"module": "@ember/
|
|
8062
|
+
"module": "@ember/component"
|
|
8007
8063
|
},
|
|
8008
8064
|
{
|
|
8009
8065
|
"file": "packages/@ember/-internals/glimmer/index.ts",
|
|
@@ -9108,7 +9164,7 @@
|
|
|
9108
9164
|
},
|
|
9109
9165
|
{
|
|
9110
9166
|
"file": "packages/@ember/-internals/metal/lib/tracked.ts",
|
|
9111
|
-
"line":
|
|
9167
|
+
"line": 15,
|
|
9112
9168
|
"decorator": "",
|
|
9113
9169
|
"access": "private",
|
|
9114
9170
|
"tagname": "Marks a property as tracked.\n\nBy default, a component's properties are expected to be static,\nmeaning you are not able to update them and have the template update accordingly.\nMarking a property as tracked means that when that property changes,\na rerender of the component is scheduled so the template is kept up to date.\n\nThere are two usages for the `@tracked` decorator, shown below.",
|
|
@@ -9125,6 +9181,41 @@
|
|
|
9125
9181
|
"class": "@ember/owner",
|
|
9126
9182
|
"module": "@ember/object"
|
|
9127
9183
|
},
|
|
9184
|
+
{
|
|
9185
|
+
"file": "packages/@ember/-internals/metal/lib/tracked.ts",
|
|
9186
|
+
"line": 77,
|
|
9187
|
+
"description": "Reactivity options for the standalone `tracked(value, options)` form.\n\n- `equals` decides whether writing a value notifies consumers; it defaults to\n `Object.is`.\n- `description` is used in development for debugging.\n\n`equals` is a function-typed property (rather than method syntax) on purpose:\nthis keeps its parameters checked strictly, so passing an `equals` typed for\nthe wrong value type is a type error instead of being silently accepted.",
|
|
9188
|
+
"class": "@ember/owner",
|
|
9189
|
+
"module": "@ember/object"
|
|
9190
|
+
},
|
|
9191
|
+
{
|
|
9192
|
+
"file": "packages/@ember/-internals/metal/lib/tracked.ts",
|
|
9193
|
+
"line": 93,
|
|
9194
|
+
"description": "Options for `tracked` used as a decorator, or as a field on a *classic* class\n(`EmberObject.extend({ foo: tracked({ value }) })`).\n\nAll properties are optional because this single shape backs several usages:\nclassic-field defaults (`tracked({ value })` / `tracked({ initializer })`) and\noptions-only native decorators (`@tracked({ equals })`). The mutually\nexclusive combinations (e.g. both `value` and `initializer`) and the\nclassic-only restriction on `value`/`initializer` are enforced at runtime via\nassertions rather than in the type, matching the runtime `isDecoratorOptions`\ncheck that accepts any object composed of these keys.\n\n- `value` / `initializer` supply a default value and are only valid on classic\n classes; native classes use class field initializers instead.\n- `equals` / `description` configure reactivity, mirroring\n {@link TrackedValueOptions}.",
|
|
9195
|
+
"class": "@ember/owner",
|
|
9196
|
+
"module": "@ember/object"
|
|
9197
|
+
},
|
|
9198
|
+
{
|
|
9199
|
+
"file": "packages/@ember/-internals/metal/lib/tracked.ts",
|
|
9200
|
+
"line": 124,
|
|
9201
|
+
"description": "`tracked` as a decorator factory: `@tracked({ equals })`, or on classic\nclasses `tracked({ value })` / `tracked({ initializer })`.",
|
|
9202
|
+
"class": "@ember/owner",
|
|
9203
|
+
"module": "@ember/object"
|
|
9204
|
+
},
|
|
9205
|
+
{
|
|
9206
|
+
"file": "packages/@ember/-internals/metal/lib/tracked.ts",
|
|
9207
|
+
"line": 129,
|
|
9208
|
+
"description": "`tracked` as a bare decorator: `@tracked foo = 1`.",
|
|
9209
|
+
"class": "@ember/owner",
|
|
9210
|
+
"module": "@ember/object"
|
|
9211
|
+
},
|
|
9212
|
+
{
|
|
9213
|
+
"file": "packages/@ember/-internals/metal/lib/tracked.ts",
|
|
9214
|
+
"line": 138,
|
|
9215
|
+
"description": "`tracked` as a standalone reactive value, usable outside of classes:\n`const count = tracked(0)`.",
|
|
9216
|
+
"class": "@ember/owner",
|
|
9217
|
+
"module": "@ember/object"
|
|
9218
|
+
},
|
|
9128
9219
|
{
|
|
9129
9220
|
"file": "packages/@ember/-internals/owner/index.ts",
|
|
9130
9221
|
"line": 24,
|
|
@@ -9759,7 +9850,7 @@
|
|
|
9759
9850
|
},
|
|
9760
9851
|
{
|
|
9761
9852
|
"file": "packages/@ember/-internals/runtime/lib/mixins/comparable.ts",
|
|
9762
|
-
"line":
|
|
9853
|
+
"line": 23,
|
|
9763
9854
|
"description": "__Required.__ You must implement this method to apply this mixin.\n\nOverride to return the result of the comparison of the two parameters. The\ncompare method should return:\n\n- `-1` if `a < b`\n- `0` if `a == b`\n- `1` if `a > b`\n\nDefault implementation raises an exception.",
|
|
9764
9855
|
"itemtype": "method",
|
|
9765
9856
|
"name": "compare",
|
|
@@ -20161,7 +20252,7 @@
|
|
|
20161
20252
|
},
|
|
20162
20253
|
{
|
|
20163
20254
|
"file": "packages/@ember/utils/lib/compare.ts",
|
|
20164
|
-
"line":
|
|
20255
|
+
"line": 52,
|
|
20165
20256
|
"description": "Compares two javascript values and returns:\n\n - -1 if the first is smaller than the second,\n - 0 if both are equal,\n - 1 if the first is greater than the second.\n\n ```javascript\n import { compare } from '@ember/utils';\n\n compare('hello', 'hello'); // 0\n compare('abc', 'dfg'); // -1\n compare(2, 1); // 1\n ```\n\nIf the types of the two objects are different precedence occurs in the\nfollowing order, with types earlier in the list considered `<` types\nlater in the list:\n\n - undefined\n - null\n - boolean\n - number\n - string\n - array\n - object\n - instance\n - function\n - class\n - date\n\n ```javascript\n import { compare } from '@ember/utils';\n\n compare('hello', 50); // 1\n compare(50, 'hello'); // -1\n ```",
|
|
20166
20257
|
"itemtype": "method",
|
|
20167
20258
|
"name": "compare",
|
|
@@ -24240,8 +24331,8 @@
|
|
|
24240
24331
|
},
|
|
24241
24332
|
{
|
|
24242
24333
|
"file": "packages/@glimmer/tracking/index.ts",
|
|
24243
|
-
"line":
|
|
24244
|
-
"description": "Marks a property as tracked. By default, values that are rendered in Ember app\ntemplates are _static_, meaning that updates to them won't cause the\napplication to rerender. Marking a property as tracked means that when that\nproperty changes, any templates that used that property, directly or\nindirectly, will rerender. For instance, consider this component:\n\n```gjs\nimport Component from '@glimmer/component';\nimport { tracked } from '@glimmer/tracking';\nimport { action } from '@ember/object';\n\nexport default class CounterComponent extends Component {\n @tracked count = 0;\n\n get timesTen() {\n return this.count * 10;\n }\n\n @action\n plusOne() {\n this.count += 1;\n }\n
|
|
24334
|
+
"line": 23,
|
|
24335
|
+
"description": "Marks a property as tracked. By default, values that are rendered in Ember app\ntemplates are _static_, meaning that updates to them won't cause the\napplication to rerender. Marking a property as tracked means that when that\nproperty changes, any templates that used that property, directly or\nindirectly, will rerender. For instance, consider this component:\n\n```gjs\nimport Component from '@glimmer/component';\nimport { tracked } from '@glimmer/tracking';\nimport { action } from '@ember/object';\n\nexport default class CounterComponent extends Component {\n @tracked count = 0;\n\n get timesTen() {\n return this.count * 10;\n }\n\n @action\n plusOne() {\n this.count += 1;\n }\n\n <template>\n <div>Count: {{this.count}}</div>\n <div>Times Ten: {{this.timesTen}}</div>\n <div>\n <button {{on \"click\" this.plusOne}}>\n Plus One\n </button>\n </div>\n </template>\n}\n```\n\nBoth the `{{this.count}}` and the `{{this.timesTen}}` properties in the\ntemplate will update whenever the button is clicked. Any tracked properties\nthat are used in any way to calculate a value that is used in the template\nwill cause a rerender when updated - this includes through method calls and\nother means:\n\n```gjs\nimport Component from '@glimmer/component';\nimport { tracked } from '@glimmer/tracking';\n\nclass Entry {\n @tracked name;\n @tracked phoneNumber;\n\n constructor(name, phoneNumber) {\n this.name = name;\n this.phoneNumber = phoneNumber;\n }\n}\n\nexport default class PhoneBookComponent extends Component {\n entries = [\n new Entry('Pizza Palace', 5551234),\n new Entry('1st Street Cleaners', 5554321),\n new Entry('Plants R Us', 5552468),\n ];\n\n // Any usage of this property will update whenever any of the names in the\n // entries arrays are updated\n get names() {\n return this.entries.map(e => e.name);\n }\n\n // Any usage of this property will update whenever any of the numbers in the\n // entries arrays are updated\n get numbers() {\n return this.getFormattedNumbers();\n }\n\n getFormattedNumbers() {\n return this.entries\n .map(e => e.phoneNumber)\n .map(number => {\n let numberString = '' + number;\n\n return numberString.slice(0, 3) + '-' + numberString.slice(3);\n });\n }\n}\n```\n\nIt's important to note that setting tracked properties will always trigger an\nupdate, even if the property is set to the same value as it was before.\n\n```js\nlet entry = new Entry('Pizza Palace', 5551234);\n// if entry was used when rendering, this would cause a rerender, even though\n// the name is being set to the same value as it was before\nentry.name = entry.name;\n```\n\n`tracked` can also be used with the classic Ember object model in a similar\nmanner to classic computed properties:\n\n```javascript\nimport EmberObject from '@ember/object';\nimport { tracked } from '@glimmer/tracking';\n\nconst Entry = EmberObject.extend({\n name: tracked(),\n phoneNumber: tracked()\n});\n```\n\nOften this is unnecessary, but to ensure robust auto-tracking behavior it is\nadvisable to mark tracked state appropriately wherever possible.\nThis form of `tracked` also accepts an optional configuration object\ncontaining either an initial `value` or an `initializer` function (but not\nboth).\n\n```javascript\nimport EmberObject from '@ember/object';\nimport { tracked } from '@glimmer/tracking';\n\nconst Entry = EmberObject.extend({\n name: tracked({ value: 'Zoey' }),\n favoriteSongs: tracked({\n initializer: () => ['Raspberry Beret', 'Time After Time']\n })\n});\n```\n\nCalling `tracked` with an initial value creates a standalone reactive\nvalue, usable outside of classes:\n\n```js\nimport { tracked } from '@glimmer/tracking';\n\nconst count = tracked(0);\n\ncount.value; // read the value, entangling with any tracking context\ncount.value = 1; // write the value, notifying consumers\ncount.get(); // function shorthand for reading\ncount.set(2); // function shorthand for writing\ncount.update((n) => n + 1); // write based on the current value, without entangling\ncount.freeze(); // prevent all future writes\n```\n\nReading `value` in a template (or in a getter used by a template) will\nrerender just like a `@tracked` property:\n\n```gjs\nimport { tracked } from '@glimmer/tracking';\nimport { on } from '@ember/modifier';\n\nconst count = tracked(0);\nconst increment = () => count.value++;\n\n<template>\n Count is: {{count.value}}\n\n <button {{on \"click\" increment}}>add one</button>\n</template>\n```\n\nThis form accepts an options object containing an `equals` function, which\ndecides whether a written value should notify consumers (it defaults to\n`Object.is`), and a `description` used for debugging:\n\n```js\nconst count = tracked(0, { equals: (a, b) => a === b });\n\ncount.value = 0; // does not notify consumers, the value did not change\n```\n\nNote: when `tracked` is called with a single plain object whose keys are all\ndrawn from `value`, `initializer`, `equals`, and `description`, it is treated\nas the configuration object for a decorator (or classic-class field), not as a\nstandalone value wrapping that object. To create a standalone reactive value\naround such an object, pass it as an initial value and include a (possibly\nempty) options argument: `tracked({ value: 5 }, {})`.\n\nThe `@tracked` decorator accepts the same options. By default, setting a\n`@tracked` property always notifies consumers, even when setting the\nproperty to the same value; passing `equals` opts in to equality-based\nnotification instead:\n\n```js\nimport { tracked } from '@glimmer/tracking';\n\nclass Counter {\n @tracked({ equals: (a, b) => a === b }) count = 0;\n\n noop = () => {\n // does not notify consumers, the value did not change\n this.count = this.count;\n };\n}\n```",
|
|
24245
24336
|
"itemtype": "method",
|
|
24246
24337
|
"name": "tracked",
|
|
24247
24338
|
"static": 1,
|
|
@@ -24252,7 +24343,7 @@
|
|
|
24252
24343
|
},
|
|
24253
24344
|
{
|
|
24254
24345
|
"file": "packages/@glimmer/tracking/index.ts",
|
|
24255
|
-
"line":
|
|
24346
|
+
"line": 225,
|
|
24256
24347
|
"description": "The `@cached` decorator can be used on getters in order to cache the return\nvalue of the getter. This is useful when a getter is expensive and used very\noften. For instance, in this guest list class, we have the `sortedGuests`\ngetter that sorts the guests alphabetically:\n\n```js\nimport { tracked } from '@glimmer/tracking';\n\nclass GuestList {\n @tracked guests = ['Zoey', 'Tomster'];\n\n get sortedGuests() {\n return this.guests.slice().sort()\n }\n}\n```\n\nEvery time `sortedGuests` is accessed, a new array will be created and sorted,\nbecause JavaScript getters do not cache by default. When the guest list is\nsmall, like the one in the example, this is not a problem. However, if the guest\nlist were to grow very large, it would mean that we would be doing a large\namount of work each time we accessed `sortedGetters`. With `@cached`, we can\ncache the value instead:\n\n```js\nimport { tracked, cached } from '@glimmer/tracking';\n\nclass GuestList {\n @tracked guests = ['Zoey', 'Tomster'];\n\n @cached\n get sortedGuests() {\n return this.guests.slice().sort()\n }\n}\n```\n\nNow the `sortedGuests` getter will be cached based on _autotracking_. It will\nonly rerun and create a new sorted array when the `guests` tracked property is\nupdated.\n\nIn general, you should avoid using `@cached` unless you have confirmed that the\ngetter you are decorating is computationally expensive. `@cached` adds a small\namount of overhead to the getter, making it more expensive. While this overhead\nis small, if `@cached` is overused it can add up to a large impact overall in\nyour app. Many getters and tracked properties are only accessed once, rendered,\nand then never rerendered, so adding `@cached` when it is unnecessary can\nnegatively impact performance.",
|
|
24257
24348
|
"itemtype": "method",
|
|
24258
24349
|
"name": "cached",
|
|
@@ -24366,6 +24457,55 @@
|
|
|
24366
24457
|
"class": "TestAdapter",
|
|
24367
24458
|
"module": "@glimmer/tracking"
|
|
24368
24459
|
},
|
|
24460
|
+
{
|
|
24461
|
+
"file": "packages/@glimmer/validator/lib/tracked-value.ts",
|
|
24462
|
+
"line": 8,
|
|
24463
|
+
"description": "A mutable reactive value.\n\nReading `value` consumes the underlying tag (entangling with any active\ntracking frame), and writing `value` dirties it.",
|
|
24464
|
+
"class": "TestAdapter",
|
|
24465
|
+
"module": "@glimmer/tracking"
|
|
24466
|
+
},
|
|
24467
|
+
{
|
|
24468
|
+
"file": "packages/@glimmer/validator/lib/tracked-value.ts",
|
|
24469
|
+
"line": 18,
|
|
24470
|
+
"description": "A reactive value that can only be read.",
|
|
24471
|
+
"class": "TestAdapter",
|
|
24472
|
+
"module": "@glimmer/tracking"
|
|
24473
|
+
},
|
|
24474
|
+
{
|
|
24475
|
+
"file": "packages/@glimmer/validator/lib/tracked-value.ts",
|
|
24476
|
+
"line": 37,
|
|
24477
|
+
"description": "The underlying value.\n\nReading entangles with the current tracking frame, and writing notifies\nconsumers (unless the configured `equals` deems the new value equal to\nthe current one).",
|
|
24478
|
+
"class": "TestAdapter",
|
|
24479
|
+
"module": "@glimmer/tracking"
|
|
24480
|
+
},
|
|
24481
|
+
{
|
|
24482
|
+
"file": "packages/@glimmer/validator/lib/tracked-value.ts",
|
|
24483
|
+
"line": 54,
|
|
24484
|
+
"description": "Function short-hand for reading `value`.",
|
|
24485
|
+
"class": "TestAdapter",
|
|
24486
|
+
"module": "@glimmer/tracking"
|
|
24487
|
+
},
|
|
24488
|
+
{
|
|
24489
|
+
"file": "packages/@glimmer/validator/lib/tracked-value.ts",
|
|
24490
|
+
"line": 61,
|
|
24491
|
+
"description": "Function short-hand for assigning `value`.\n\nReturns `true` if the value changed (and consumers were notified),\n`false` if the new value was equal to the current one.",
|
|
24492
|
+
"class": "TestAdapter",
|
|
24493
|
+
"module": "@glimmer/tracking"
|
|
24494
|
+
},
|
|
24495
|
+
{
|
|
24496
|
+
"file": "packages/@glimmer/validator/lib/tracked-value.ts",
|
|
24497
|
+
"line": 87,
|
|
24498
|
+
"description": "Update the value based on the current value, without consuming it.",
|
|
24499
|
+
"class": "TestAdapter",
|
|
24500
|
+
"module": "@glimmer/tracking"
|
|
24501
|
+
},
|
|
24502
|
+
{
|
|
24503
|
+
"file": "packages/@glimmer/validator/lib/tracked-value.ts",
|
|
24504
|
+
"line": 94,
|
|
24505
|
+
"description": "Prevents further updates, making the TrackedValue behave as a\nReadOnlyReactive.",
|
|
24506
|
+
"class": "TestAdapter",
|
|
24507
|
+
"module": "@glimmer/tracking"
|
|
24508
|
+
},
|
|
24369
24509
|
{
|
|
24370
24510
|
"file": "packages/@glimmer/validator/lib/tracking.ts",
|
|
24371
24511
|
"line": 10,
|
|
@@ -24541,7 +24681,7 @@
|
|
|
24541
24681
|
},
|
|
24542
24682
|
{
|
|
24543
24683
|
"message": "unknown tag: note",
|
|
24544
|
-
"line": " packages/@ember/-internals/glimmer/lib/helper.ts:
|
|
24684
|
+
"line": " packages/@ember/-internals/glimmer/lib/helper.ts:319"
|
|
24545
24685
|
},
|
|
24546
24686
|
{
|
|
24547
24687
|
"message": "unknown tag: decorator",
|
|
@@ -24549,7 +24689,7 @@
|
|
|
24549
24689
|
},
|
|
24550
24690
|
{
|
|
24551
24691
|
"message": "unknown tag: decorator",
|
|
24552
|
-
"line": " packages/@ember/-internals/metal/lib/tracked.ts:
|
|
24692
|
+
"line": " packages/@ember/-internals/metal/lib/tracked.ts:15"
|
|
24553
24693
|
},
|
|
24554
24694
|
{
|
|
24555
24695
|
"message": "unknown tag: internal",
|
|
@@ -24715,6 +24855,10 @@
|
|
|
24715
24855
|
"message": "unknown tag: debug",
|
|
24716
24856
|
"line": " packages/@glimmer/runtime/lib/scope.ts:86"
|
|
24717
24857
|
},
|
|
24858
|
+
{
|
|
24859
|
+
"message": "Missing item type\nThe brand for the curly component manager lives in its own module so that\ncode which only needs to *detect* the curly manager (e.g. the resolver)\ndoes not have to import the manager itself (and with it the classic\ncomponent machinery).",
|
|
24860
|
+
"line": " packages/@ember/-internals/glimmer/lib/component-managers/curly-brand.ts:1"
|
|
24861
|
+
},
|
|
24718
24862
|
{
|
|
24719
24863
|
"message": "Missing item type\nThis \"upgrades\" a route template into a invocable component. Conceptually\nit can be 1:1 for each unique `Template`, but it's also cheap to construct,\nso unless the stability is desirable for other reasons, it's probably not\nworth caching this.",
|
|
24720
24864
|
"line": " packages/@ember/-internals/glimmer/lib/component-managers/route-template.ts:113"
|
|
@@ -24784,68 +24928,80 @@
|
|
|
24784
24928
|
"line": " packages/@ember/-internals/glimmer/lib/views/outlet.ts:122"
|
|
24785
24929
|
},
|
|
24786
24930
|
{
|
|
24787
|
-
"message": "Missing item type",
|
|
24788
|
-
"line": " packages/@ember/-internals/glimmer/lib/
|
|
24789
|
-
},
|
|
24790
|
-
{
|
|
24791
|
-
"message": "Missing item type\nThe type of a function-based helper.",
|
|
24792
|
-
"line": " packages/@ember/-internals/glimmer/lib/helper.ts:325"
|
|
24931
|
+
"message": "Missing item type\nThe interface the `RendererState` needs from a render root. The base\nrenderer only ever creates `ComponentRootState`s; the classic renderer\n(`./renderer`) adds `ClassicRootState` for outlet/classic-component roots.",
|
|
24932
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:68"
|
|
24793
24933
|
},
|
|
24794
24934
|
{
|
|
24795
24935
|
"message": "Missing item type\nDestroys the render tree and removes all rendered content from the element rendered into",
|
|
24796
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24936
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:413"
|
|
24797
24937
|
},
|
|
24798
24938
|
{
|
|
24799
24939
|
"message": "Missing item type\nThe GlimmerRenderResult from the last render. Used to get positional\ninformation (firstNode) when a re-render replaces the content, so\nthat the new content is placed at the same DOM position.",
|
|
24800
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24940
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:421"
|
|
24801
24941
|
},
|
|
24802
24942
|
{
|
|
24803
24943
|
"message": "Missing item type\nThe component definition to render.\n\nAny component that has had its manager registered is valid.\nFor the component-types that ship with ember, manager registration\ndoes not need to be worried about.",
|
|
24804
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24944
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:452"
|
|
24805
24945
|
},
|
|
24806
24946
|
{
|
|
24807
24947
|
"message": "Missing item type\nThe element to render the component in to.",
|
|
24808
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24948
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:466"
|
|
24809
24949
|
},
|
|
24810
24950
|
{
|
|
24811
24951
|
"message": "Missing item type\nOptional owner. Defaults to `{}`, can be any object, but will need to implement the [Owner](https://api.emberjs.com/ember/release/classes/Owner) API for components within this render tree to access services.",
|
|
24812
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24952
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:471"
|
|
24813
24953
|
},
|
|
24814
24954
|
{
|
|
24815
24955
|
"message": "Missing item type\nOptionally configure the rendering environment",
|
|
24816
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24956
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:475"
|
|
24817
24957
|
},
|
|
24818
24958
|
{
|
|
24819
24959
|
"message": "Missing item type\nWhen false, modifiers will not run.",
|
|
24820
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24960
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:479"
|
|
24821
24961
|
},
|
|
24822
24962
|
{
|
|
24823
24963
|
"message": "Missing item type\nAll other options are forwarded to the underlying renderer.\n(its API is currently private and out of scope for this RFC,\n so passing additional things here is also considered private API)",
|
|
24824
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24964
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:483"
|
|
24825
24965
|
},
|
|
24826
24966
|
{
|
|
24827
24967
|
"message": "Missing item type\nThese args get passed to the rendered component\n\nIf your args are reactive, re-rendering will happen automatically.",
|
|
24828
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24968
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:491"
|
|
24829
24969
|
},
|
|
24830
24970
|
{
|
|
24831
24971
|
"message": "Missing item type\nSAFETY: we should figure out what we need out of a `document` and narrow the API.\n this exercise should also end up beginning to define what we need for CLI rendering (or to other outputs)",
|
|
24832
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24972
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:500"
|
|
24833
24973
|
},
|
|
24834
24974
|
{
|
|
24835
24975
|
"message": "Missing item type\nReplace all contents, if we've rendered multiple times.\n\nhttps://github.com/emberjs/rfcs/pull/1099/files#diff-2b962105b9083ca84579cdc957f27f49407440f3c5078083fa369ec18cc46da8R365\n\nWe could later add an option to not do this behavior\n\nNOTE: destruction is async",
|
|
24836
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24976
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:521"
|
|
24837
24977
|
},
|
|
24838
24978
|
{
|
|
24839
24979
|
"message": "Missing item type\nWe can only replace the inner HTML the first time.\nBecause destruction is async, it won't be safe to\ndo this again, and we'll have to rely on the above destroy.",
|
|
24840
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24980
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:532"
|
|
24841
24981
|
},
|
|
24842
24982
|
{
|
|
24843
24983
|
"message": "Missing item type\nIf there's an existing render result with valid bounds, use its\nfirstNode as the nextSibling so that new content is inserted at\nthe same DOM position. This ensures stable ordering when multiple\nrenderComponent calls target the same element and one is re-invoked\n(e.g., due to tracked dependency changes).\n\nThe old content's DOM nodes are still present (destruction is async),\nso firstNode() is a valid position reference. The new content is placed\nBEFORE the old content. When the old content is eventually destroyed\n(async clear of bounds), the new content remains in the correct position.",
|
|
24844
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24984
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:541"
|
|
24845
24985
|
},
|
|
24846
24986
|
{
|
|
24847
24987
|
"message": "Missing item type\nSAFETY: are there consequences for being looser with *this* owner?\n the public API for `owner` is kinda `Partial<InternalOwner>`\n aka: implement only what you need.\n But for actual ember apps, you *need* to implement everything\n an app needs (which will actually change and become less over time)",
|
|
24848
|
-
"line": " packages/@ember/-internals/glimmer/lib/renderer.ts:
|
|
24988
|
+
"line": " packages/@ember/-internals/glimmer/lib/base-renderer.ts:609"
|
|
24989
|
+
},
|
|
24990
|
+
{
|
|
24991
|
+
"message": "Missing item type\nThe brand for classic (class-based) helpers lives in its own module so that\ncode which only needs to *detect* classic helpers (e.g. the resolver) does\nnot have to import the classic `Helper` base class (and with it the classic\nobject model: `EmberObject`, `Mixin`, meta, etc.).",
|
|
24992
|
+
"line": " packages/@ember/-internals/glimmer/lib/helper-brand.ts:1"
|
|
24993
|
+
},
|
|
24994
|
+
{
|
|
24995
|
+
"message": "Missing item type",
|
|
24996
|
+
"line": " packages/@ember/-internals/glimmer/lib/helper.ts:135"
|
|
24997
|
+
},
|
|
24998
|
+
{
|
|
24999
|
+
"message": "Missing item type\nThe type of a function-based helper.",
|
|
25000
|
+
"line": " packages/@ember/-internals/glimmer/lib/helper.ts:319"
|
|
25001
|
+
},
|
|
25002
|
+
{
|
|
25003
|
+
"message": "Missing item type\nThe resolver used by the classic application `Renderer`. It extends the\nshared `ResolverImpl` with the keywords that require the router and engine\ninfrastructure (`{{outlet}}` and `{{mount}}`). Keeping these out of the\nbase resolver means renderers that have no router (e.g. `renderComponent`)\ndo not pull the outlet/engine machinery into the build.",
|
|
25004
|
+
"line": " packages/@ember/-internals/glimmer/lib/router-resolver.ts:13"
|
|
24849
25005
|
},
|
|
24850
25006
|
{
|
|
24851
25007
|
"message": "Missing item type\nTest skipped because when an error occurs,\nwe mess up the cache used by renderComponent.",
|
|
@@ -25045,7 +25201,27 @@
|
|
|
25045
25201
|
},
|
|
25046
25202
|
{
|
|
25047
25203
|
"message": "Missing item type",
|
|
25048
|
-
"line": " packages/@ember/-internals/metal/lib/tracked.ts:
|
|
25204
|
+
"line": " packages/@ember/-internals/metal/lib/tracked.ts:15"
|
|
25205
|
+
},
|
|
25206
|
+
{
|
|
25207
|
+
"message": "Missing item type\nReactivity options for the standalone `tracked(value, options)` form.\n\n- `equals` decides whether writing a value notifies consumers; it defaults to\n `Object.is`.\n- `description` is used in development for debugging.\n\n`equals` is a function-typed property (rather than method syntax) on purpose:\nthis keeps its parameters checked strictly, so passing an `equals` typed for\nthe wrong value type is a type error instead of being silently accepted.",
|
|
25208
|
+
"line": " packages/@ember/-internals/metal/lib/tracked.ts:77"
|
|
25209
|
+
},
|
|
25210
|
+
{
|
|
25211
|
+
"message": "Missing item type\nOptions for `tracked` used as a decorator, or as a field on a *classic* class\n(`EmberObject.extend({ foo: tracked({ value }) })`).\n\nAll properties are optional because this single shape backs several usages:\nclassic-field defaults (`tracked({ value })` / `tracked({ initializer })`) and\noptions-only native decorators (`@tracked({ equals })`). The mutually\nexclusive combinations (e.g. both `value` and `initializer`) and the\nclassic-only restriction on `value`/`initializer` are enforced at runtime via\nassertions rather than in the type, matching the runtime `isDecoratorOptions`\ncheck that accepts any object composed of these keys.\n\n- `value` / `initializer` supply a default value and are only valid on classic\n classes; native classes use class field initializers instead.\n- `equals` / `description` configure reactivity, mirroring\n {@link TrackedValueOptions}.",
|
|
25212
|
+
"line": " packages/@ember/-internals/metal/lib/tracked.ts:93"
|
|
25213
|
+
},
|
|
25214
|
+
{
|
|
25215
|
+
"message": "Missing item type\n`tracked` as a decorator factory: `@tracked({ equals })`, or on classic\nclasses `tracked({ value })` / `tracked({ initializer })`.",
|
|
25216
|
+
"line": " packages/@ember/-internals/metal/lib/tracked.ts:124"
|
|
25217
|
+
},
|
|
25218
|
+
{
|
|
25219
|
+
"message": "Missing item type\n`tracked` as a bare decorator: `@tracked foo = 1`.",
|
|
25220
|
+
"line": " packages/@ember/-internals/metal/lib/tracked.ts:129"
|
|
25221
|
+
},
|
|
25222
|
+
{
|
|
25223
|
+
"message": "Missing item type\n`tracked` as a standalone reactive value, usable outside of classes:\n`const count = tracked(0)`.",
|
|
25224
|
+
"line": " packages/@ember/-internals/metal/lib/tracked.ts:138"
|
|
25049
25225
|
},
|
|
25050
25226
|
{
|
|
25051
25227
|
"message": "Missing item type\nA type registry for the DI system, which other participants in the DI system\ncan register themselves into with declaration merging. The contract for this\ntype is that its keys are the `Type` from a `FullName`, and each value for a\n`Type` is another registry whose keys are the `Name` from a `FullName`. The\nmechanic for providing a registry is [declaration merging][handbook].\n\n[handbook]: https://www.typescriptlang.org/docs/handbook/declaration-merging.html\n\nFor example, Ember's `@ember/service` module includes this set of definitions:\n\n```ts\nexport default class Service extends EmberObject {}\n\n// For concrete singleton classes to be merged into.\ninterface Registry extends Record<string, Service> {}\n\ndeclare module '@ember/owner' {\n service: Registry;\n}\n```\n\nDeclarations of services can then include the registry:\n\n```ts\nimport Service from '@ember/service';\n\nexport default class Session extends Service {\n login(username: string, password: string) {\n // ...\n }\n}\n\ndeclare module '@ember/service' {\n interface Registry {\n session: Session;\n }\n}\n```\n\nThen users of the `Owner` API will be able to do things like this with strong\ntype safety guarantees:\n\n```ts\ngetOwner(this)?.lookup('service:session').login(\"hello\", \"1234abcd\");\n```",
|
|
@@ -27475,6 +27651,34 @@
|
|
|
27475
27651
|
"message": "Missing item type\nCreates a global autotracking transaction. This will prevent any backflow\nin any `track` calls within the transaction, even if they are not\nexternally consumed.\n\n`runInAutotrackingTransaction` can be called within itself, and it will add\nonto the existing transaction if one exists.\n\nTODO: Only throw an error if the `track` is consumed.",
|
|
27476
27652
|
"line": " packages/@glimmer/validator/lib/debug.ts:104"
|
|
27477
27653
|
},
|
|
27654
|
+
{
|
|
27655
|
+
"message": "Missing item type\nA mutable reactive value.\n\nReading `value` consumes the underlying tag (entangling with any active\ntracking frame), and writing `value` dirties it.",
|
|
27656
|
+
"line": " packages/@glimmer/validator/lib/tracked-value.ts:8"
|
|
27657
|
+
},
|
|
27658
|
+
{
|
|
27659
|
+
"message": "Missing item type\nA reactive value that can only be read.",
|
|
27660
|
+
"line": " packages/@glimmer/validator/lib/tracked-value.ts:18"
|
|
27661
|
+
},
|
|
27662
|
+
{
|
|
27663
|
+
"message": "Missing item type\nThe underlying value.\n\nReading entangles with the current tracking frame, and writing notifies\nconsumers (unless the configured `equals` deems the new value equal to\nthe current one).",
|
|
27664
|
+
"line": " packages/@glimmer/validator/lib/tracked-value.ts:37"
|
|
27665
|
+
},
|
|
27666
|
+
{
|
|
27667
|
+
"message": "Missing item type\nFunction short-hand for reading `value`.",
|
|
27668
|
+
"line": " packages/@glimmer/validator/lib/tracked-value.ts:54"
|
|
27669
|
+
},
|
|
27670
|
+
{
|
|
27671
|
+
"message": "Missing item type\nFunction short-hand for assigning `value`.\n\nReturns `true` if the value changed (and consumers were notified),\n`false` if the new value was equal to the current one.",
|
|
27672
|
+
"line": " packages/@glimmer/validator/lib/tracked-value.ts:61"
|
|
27673
|
+
},
|
|
27674
|
+
{
|
|
27675
|
+
"message": "Missing item type\nUpdate the value based on the current value, without consuming it.",
|
|
27676
|
+
"line": " packages/@glimmer/validator/lib/tracked-value.ts:87"
|
|
27677
|
+
},
|
|
27678
|
+
{
|
|
27679
|
+
"message": "Missing item type\nPrevents further updates, making the TrackedValue behave as a\nReadOnlyReactive.",
|
|
27680
|
+
"line": " packages/@glimmer/validator/lib/tracked-value.ts:94"
|
|
27681
|
+
},
|
|
27478
27682
|
{
|
|
27479
27683
|
"message": "Missing item type\nAn object that that tracks @tracked properties that were consumed.",
|
|
27480
27684
|
"line": " packages/@glimmer/validator/lib/tracking.ts:10"
|