[SOLVED] How to write this in typescript?

Hi community,
Been working on migrating to typescript and I’ve been getting this warning ‘Unsafe assignment of an any value’ for the following declaration example:
const prefabInstance = this.prefab.resource.instantiate();

Wondering if you had any insights on how this should be written or if I’m missing a cast?


Edit: for anybody interested, this will get rid of the any error:
const prefabInstance = (this.prefab.resource as pc.Template).instantiate();