Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

inversify-hapi-decorators

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

inversify-hapi-decorators - npm Package Compare versions

Comparing version 0.0.5 to 0.0.6

18

dts/decorators.d.ts
import { interfaces } from "./interfaces";
import { RouteAdditionalConfigurationOptions } from "hapi";
export declare function Controller(path: string, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): (target: any) => void;
export declare function Get(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Post(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Put(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Patch(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Head(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Delete(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Options(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Method(method: string, options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Controller(path: string, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): (target: any) => void;
export declare function Get(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Post(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Put(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Patch(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Head(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Delete(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Options(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;
export declare function Method(method: string, options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator;

@@ -8,3 +8,3 @@ import * as hapi from "hapi";

path: string;
config: RouteAdditionalConfigurationOptions;
config?: RouteAdditionalConfigurationOptions;
middleware: Middleware[];

@@ -25,3 +25,3 @@ target: any;

method: string;
config: RouteAdditionalConfigurationOptions;
config?: RouteAdditionalConfigurationOptions;
key: string;

@@ -28,0 +28,0 @@ }

{
"name": "inversify-hapi-decorators",
"version": "0.0.5",
"version": "0.0.6",
"description": "Some utilities for the development of hapijs rest applications with Inversify",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -5,3 +5,3 @@ import { interfaces } from "./interfaces";

export function Controller(path: string, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]) {
export function Controller(path: string, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]) {
return function (target: any) {

@@ -13,27 +13,27 @@ let metadata: interfaces.ControllerMetadata = {path, config, middleware, target};

export function Get(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
export function Get(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
return Method("get", options, config, ...middleware);
}
export function Post(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
export function Post(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
return Method("post", options, config, ...middleware);
}
export function Put(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
export function Put(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
return Method("put", options, config, ...middleware);
}
export function Patch(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
export function Patch(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
return Method("patch", options, config, ...middleware);
}
export function Head(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
export function Head(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
return Method("head", options, config, ...middleware);
}
export function Delete(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
export function Delete(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
return Method("delete", options, config, ...middleware);
}
export function Options(options: interfaces.RouteOptions, config: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
export function Options(options: interfaces.RouteOptions, config?: RouteAdditionalConfigurationOptions, ...middleware: interfaces.Middleware[]): interfaces.HandlerDecorator {
return Method("opts", options, config, ...middleware);

@@ -45,3 +45,3 @@ }

options: interfaces.RouteOptions,
config: RouteAdditionalConfigurationOptions,
config?: RouteAdditionalConfigurationOptions,
...middleware: interfaces.Middleware[]

@@ -48,0 +48,0 @@ ): interfaces.HandlerDecorator {

@@ -11,3 +11,3 @@ import * as hapi from "hapi";

path: string;
config: RouteAdditionalConfigurationOptions;
config?: RouteAdditionalConfigurationOptions;
middleware: Middleware[];

@@ -25,3 +25,3 @@ target: any;

method: string;
config: RouteAdditionalConfigurationOptions
config?: RouteAdditionalConfigurationOptions
key: string;

@@ -28,0 +28,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc