File tree 1 file changed +6
-2
lines changed
1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 1
- import { get } from ' @ember/helper' ;
1
+ import { helper } from ' @ember/component /helper' ;
2
2
import type { TestContext } from ' @ember/test-helpers' ;
3
3
import { render } from ' @ember/test-helpers' ;
4
4
import Component from ' @glimmer/component' ;
@@ -27,6 +27,10 @@ export async function reactiveContext<T extends Model>(
27
27
_fields .push (field .name );
28
28
});
29
29
30
+ const lowPolyGet = helper (([obj , prop ]: [obj : TestContext , prop : string ]): unknown => {
31
+ return obj [prop ];
32
+ });
33
+
30
34
// eslint-disable-next-line @typescript-eslint/no-empty-object-type
31
35
interface ReactiveComponent extends Record <string , string > {}
32
36
class ReactiveComponent extends Component {
@@ -38,7 +42,7 @@ export async function reactiveContext<T extends Model>(
38
42
<div class =" reactive-context" >
39
43
<ul >
40
44
{{#each this . __allFields as | prop | }}
41
- <li >{{prop }} : {{get this prop}} </li >
45
+ <li >{{prop }} : {{lowPolyGet this prop}} </li >
42
46
{{/each }}
43
47
</ul >
44
48
</div >
You can’t perform that action at this time.
0 commit comments