diff --git a/types/case-sensitive-paths-webpack-plugin/case-sensitive-paths-webpack-plugin-tests.ts b/types/case-sensitive-paths-webpack-plugin/case-sensitive-paths-webpack-plugin-tests.ts index a4370cff73..2c09b7e3c9 100644 --- a/types/case-sensitive-paths-webpack-plugin/case-sensitive-paths-webpack-plugin-tests.ts +++ b/types/case-sensitive-paths-webpack-plugin/case-sensitive-paths-webpack-plugin-tests.ts @@ -1,15 +1,20 @@ -import { Configuration } from 'webpack'; +import { Compiler, Configuration, Plugin } from 'webpack'; import CaseSensitivePathsWebpackPlugin = require('case-sensitive-paths-webpack-plugin'); const options: CaseSensitivePathsWebpackPlugin.Options = { debug: true, }; +const compiler: Compiler = new Compiler(); +const plugin: Plugin = new CaseSensitivePathsWebpackPlugin(); + +plugin.apply(compiler); const c: Configuration = { plugins: [ new CaseSensitivePathsWebpackPlugin(), new CaseSensitivePathsWebpackPlugin({ - debug: true + debug: true, }), + plugin, ], }; diff --git a/types/case-sensitive-paths-webpack-plugin/index.d.ts b/types/case-sensitive-paths-webpack-plugin/index.d.ts index 58cdccf25f..208766a904 100644 --- a/types/case-sensitive-paths-webpack-plugin/index.d.ts +++ b/types/case-sensitive-paths-webpack-plugin/index.d.ts @@ -4,12 +4,14 @@ // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.3 -import { Plugin } from 'webpack'; +import { Plugin, Compiler } from 'webpack'; export = CaseSensitivePathsWebpackPlugin; declare class CaseSensitivePathsWebpackPlugin extends Plugin { constructor(options?: CaseSensitivePathsWebpackPlugin.Options); + + apply(compiler: Compiler): void; } declare namespace CaseSensitivePathsWebpackPlugin { diff --git a/types/html-webpack-plugin/index.d.ts b/types/html-webpack-plugin/index.d.ts index 25b615a7be..090e4c5323 100644 --- a/types/html-webpack-plugin/index.d.ts +++ b/types/html-webpack-plugin/index.d.ts @@ -6,14 +6,16 @@ // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.3 -import { Plugin, compilation } from 'webpack'; +import { Plugin, compilation, Compiler } from 'webpack'; import { AsyncSeriesWaterfallHook } from 'tapable'; import { Options as HtmlMinifierOptions } from 'html-minifier'; export = HtmlWebpackPlugin; declare class HtmlWebpackPlugin extends Plugin { - constructor(options?: HtmlWebpackPlugin.Options); + constructor(options?: HtmlWebpackPlugin.Options); + + apply(compiler: Compiler): void; } declare namespace HtmlWebpackPlugin {