Are you calling the above code inside your dynamic dataset’s onReady() function? If not, then try it.
https://www.wix.com/velo/reference/wix-dataset/dynamicdataset/onready
Are you calling the above code inside your dynamic dataset’s onReady() function? If not, then try it.
https://www.wix.com/velo/reference/wix-dataset/dynamicdataset/onready