mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
Add EventStream interface to WebpackHotMiddleware
The publish method was missing
This commit is contained in:
parent
a463f8d8c0
commit
ee0c19656e
8
types/webpack-hot-middleware/index.d.ts
vendored
8
types/webpack-hot-middleware/index.d.ts
vendored
@ -1,4 +1,4 @@
|
||||
// Type definitions for webpack-hot-middleware 2.15
|
||||
// Type definitions for webpack-hot-middleware 2.16
|
||||
// Project: https://github.com/glenjamin/webpack-hot-middleware#readme
|
||||
// Definitions by: Benjamin Lim <https://github.com/bumbleblym>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
@ -11,7 +11,7 @@ export = WebpackHotMiddleware;
|
||||
declare function WebpackHotMiddleware(
|
||||
compiler: compiler.Compiler,
|
||||
options?: WebpackHotMiddleware.Options
|
||||
): NextHandleFunction;
|
||||
): NextHandleFunction & WebpackHotMiddleware.EventStream;
|
||||
|
||||
declare namespace WebpackHotMiddleware {
|
||||
interface Options {
|
||||
@ -21,4 +21,8 @@ declare namespace WebpackHotMiddleware {
|
||||
}
|
||||
|
||||
type Logger = (message?: any, ...optionalParams: any[]) => void;
|
||||
|
||||
interface EventStream {
|
||||
publish(payload: any): void;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user