fastify-sse-v2
Advanced tools
Comparing version 1.0.2 to 1.0.3
@@ -9,2 +9,6 @@ # Changelog | ||
## [1.0.3] | ||
### Fixed | ||
- type definitions referencing itself | ||
## [1.0.2] | ||
@@ -18,5 +22,6 @@ ### Fixed | ||
[Unreleased]: https://github.com/nodefactoryio/fastify-sse-v2/compare/v1.0.2...HEAD | ||
[Unreleased]: https://github.com/nodefactoryio/fastify-sse-v2/compare/v1.0.3...HEAD | ||
[1.0.3]: https://github.com/nodefactoryio/fastify-sse-v2/compare/v1.0.2...v1.0.3 | ||
[1.0.2]: https://github.com/nodefactoryio/fastify-sse-v2/compare/v1.0.1...v1.0.2 | ||
[1.0.1]: https://github.com/nodefactoryio/fastify-sse-v2/compare/v1.0.0...v1.0.1 | ||
[1.0.0]: https://github.com/nodefactoryio/fastify-sse-v2/releases/tag/v1.0.0 |
@@ -1,5 +0,6 @@ | ||
/// <reference path="index.d.ts" /> | ||
/// <reference types="node" /> | ||
/// <reference types="fastify" /> | ||
export declare const FastifySSEPlugin: (instance: import("fastify").FastifyInstance<import("http").Server, import("http").IncomingMessage, import("http").ServerResponse>, options: import("./types").SsePluginOptions, callback: (err?: import("fastify").FastifyError) => void) => void; | ||
import { IncomingMessage, Server, ServerResponse } from "http"; | ||
import { Plugin } from "fastify"; | ||
import { SsePluginOptions } from "./types"; | ||
export declare const FastifySSEPlugin: Plugin<Server, IncomingMessage, ServerResponse, SsePluginOptions>; | ||
declare module "fastify" { | ||
@@ -6,0 +7,0 @@ interface EventMessage { |
/// <reference types="node" /> | ||
import fastify from "fastify"; | ||
import { Plugin } from "fastify"; | ||
import { IncomingMessage, Server, ServerResponse } from "http"; | ||
import { SsePluginOptions } from "./types"; | ||
export declare const plugin: fastify.Plugin<Server, IncomingMessage, ServerResponse, SsePluginOptions>; | ||
export declare const plugin: Plugin<Server, IncomingMessage, ServerResponse, SsePluginOptions>; |
{ | ||
"name": "fastify-sse-v2", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"description": "Fastify plugin for sending server side events.", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
import fastifyPlugin from "fastify-plugin"; | ||
import {plugin} from "./plugin"; | ||
import {IncomingMessage, Server, ServerResponse} from "http"; | ||
import {Plugin} from "fastify"; | ||
import {SsePluginOptions} from "./types"; | ||
export const FastifySSEPlugin = fastifyPlugin(plugin, { | ||
name: "fastify-sse-v2", | ||
fastify: "2.x", | ||
}); | ||
export const FastifySSEPlugin: Plugin<Server, IncomingMessage, ServerResponse, SsePluginOptions> | ||
= fastifyPlugin(plugin, { | ||
name: "fastify-sse-v2", | ||
fastify: "2.x", | ||
}); | ||
@@ -9,0 +13,0 @@ declare module "fastify" { |
@@ -1,2 +0,2 @@ | ||
import fastify, {EventMessage, FastifyReply} from "fastify"; | ||
import {EventMessage, FastifyReply, Plugin} from "fastify"; | ||
import {IncomingMessage, Server, ServerResponse} from "http"; | ||
@@ -7,3 +7,3 @@ import {SsePluginOptions} from "./types"; | ||
export const plugin: fastify.Plugin<Server, IncomingMessage, ServerResponse, SsePluginOptions> = | ||
export const plugin: Plugin<Server, IncomingMessage, ServerResponse, SsePluginOptions> = | ||
async function (instance, options): Promise<void> { | ||
@@ -10,0 +10,0 @@ instance.decorateReply( |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
19378
236