Skip to content

[ts] Could not find a declaration file for module in .js file (importing Vue ESM version) #51322

@David-Else

Description

@David-Else
  • VSCode Version: 1.24.0
  • OS Version: Fedora 28

Steps to Reproduce:

  1. npm install vue
  2. try to install the ESM module version of view:

import Vue from '../node_modules/vue/dist/vue.esm.browser.js';

and get error:

[ts]
Could not find a declaration file for module '../node_modules/vue/dist/vue.esm.browser.js'. '(various folders)/node_modules/vue/dist/vue.esm.browser.js' implicitly has an 'any' type.
  Try `npm install @types/vue` if it exists or add a new declaration (.d.ts) file containing `declare module 'vue';`
module "(various folders)/node_modules/vue/dist/vue.esm.browser"

As this is a .js file, I assume it is an error that I now need to supply a declaration file? This just started to happen on the same file the moment after I updated to 1.24

Does this issue occur when all extensions are disabled?: Yes

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions