Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TsconfigPathsPlugin type not compatible with webpack 5 #65

Closed
brett-east opened this issue Mar 6, 2021 · 2 comments
Closed

TsconfigPathsPlugin type not compatible with webpack 5 #65

brett-east opened this issue Mar 6, 2021 · 2 comments

Comments

@brett-east
Copy link

I'm trying to upgrade to webpack 5, but I'm now getting a type error when
trying to use the TsconfigPathsPlugin.

resolve: {
    extensions: [...],

    // resolve aliases from tsconfig.server.json
    plugins: [
      new TsconfigPathsPlugin({ // type error here
        configFile: './tsconfig.server.json',
      }),
    ],

    alias: {...},
},

I get the following error:

Type 'TsconfigPathsPlugin' is not assignable to type '"..." | ResolvePluginInstance'.
Type 'TsconfigPathsPlugin' is not assignable to type 'ResolvePluginInstance'.
Types of property 'apply' are incompatible.

I have the feeling that this isn't a widespread issue as I can't see any mention
of it in other places, but I would have thought that I'd be able to find at least someone
that has come across the same problem.

@MitchTalmadge
Copy link

Is this the same as #61 ?

@brett-east
Copy link
Author

Is this the same as #61 ?

It is, sorry, I forgot I even commented on #61. I'm going to close this in favour of that issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants