I am using PrimeNg v11.x element. Application is working fine with scrollHeight value set from a variable but the jasmine test is failing with error:
TypeError: Cannot set property scrollHeight of [object Element] which has only a getter
<p-tree
#tree
[value]="nodes"
selectionMode="checkbox"
[scrollHeight]="scrollHeight"
virtualScroll="true"
virtualNodeHeight="33"
></p-tree>
The test succeeds if i hard code the height value.
Can anyone help how to fix this issue?
Thanks
Try this it may help you. import the module that you are using like TreeModule.