The documentation on how to write plugins for nuxt-ts seems to be outdated. This is a simple reproduction.
This project was set up using create-nuxt-app@latest. A plugin was added according and using the example code of the Nuxt.js/TypeScript Cookbook.
How to reproduce the error message:
- Clone, install, etc.
- Open the start page
pages/index.vue
in your IDE (tested with VS Code) - Take a look at line 35. You should see a Vetur warning for
$myInjectedFunction
:Property '$myInjectedFunction' does not exist on type 'CombinedVueInstance<Vue, unknown, unknown, unknown, Readonly<Record<never, any>>>'.Vetur(2339)