After #19444 was merged, the devel branch compiler can syntax check NimScript files properly. Therefore, the Visual Studio Code won't report errors for correct NimScript files anymore.
Try the devel release to verify whether it works for you. It will be backported to 1.6.x too.