Skip to content

Cannot define a module for a specific file extension in 2.4.1 #16769

Closed
@vekexasia

Description

@vekexasia

TypeScript Version: 2.4.1
Code

// A *self-contained* demonstration of the problem follows...
declare module "*.vue" {
  import Vue from 'vue'
  export default typeof Vue
}

Expected behavior:
A file with the above content used to work when importing .vue files.
In 2.4.1 It looks like the file is not taken into account as every .vue file gets imported as "string"?
Actual behavior:
Everything seems to be imported as string?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Working as IntendedThe behavior described is the intended behavior; this is not a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions