Calling ref() or shallowRef() without an argument or explicit type parameter creates a Ref<any>. Vue’s
type overloads allow this zero-argument form, which silently bypasses TypeScript’s type checking, even when noImplicitAny is enabled. The
any type then propagates to every consumer of the ref, undermining type safety throughout the component.
To fix the issue, pass an initial value so TypeScript can infer the type, or provide an explicit generic type parameter.
<script setup lang="ts"> const count = ref(); // Noncompliant: inferred as Ref<any> const data = shallowRef(); // Noncompliant: inferred as Ref<any> </script>
<script setup lang="ts"> const count = ref(0); // inferred as Ref<number> const data = shallowRef<string[]>([]); // explicit type parameter </script>