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

di-ts

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

di-ts - npm Package Compare versions

Comparing version 0.0.9 to 0.0.10

7

di-ts.d.ts
/// <reference path="index.d.ts"/>
declare module "di-ts" {
import diTS from "./index"
export = diTS
export var Injector: typeof di.Injector;
export function Inject(classFunc: any): void;
export function Provide(targetClassFunc: any): (classFunc: any) => void;
}
/// <reference path="di.d.ts" />
import * as di from 'di';
declare module diTS {
var Injector: typeof di.Injector;
function Inject(classFunc: any): void;
function Provide(targetClassFunc: any): (classFunc: any) => void;
}
export = diTS;
export declare var Injector: typeof di.Injector;
export declare function Inject(classFunc: any): void;
export declare function Provide(targetClassFunc: any): (classFunc: any) => void;
/// <reference path="./di.d.ts"/>
require('reflect-metadata');
var di = require('di');
var diTS;
(function (diTS) {
diTS.Injector = di.Injector;
function Inject(classFunc) {
var dependencies = Reflect.getMetadata("design:paramtypes", classFunc) || [];
di.annotate.apply(di, [classFunc].concat(dependencies.map(function (dep) { return new di.Inject(dep); })));
}
diTS.Inject = Inject;
function Provide(targetClassFunc) {
return function (classFunc) {
di.annotate(classFunc, new di.Provide(targetClassFunc));
};
}
diTS.Provide = Provide;
})(diTS || (diTS = {}));
module.exports = diTS;
exports.Injector = di.Injector;
function Inject(classFunc) {
var dependencies = Reflect.getMetadata("design:paramtypes", classFunc) || [];
di.annotate.apply(di, [classFunc].concat(dependencies.map(function (dep) { return new di.Inject(dep); })));
}
exports.Inject = Inject;
function Provide(targetClassFunc) {
return function (classFunc) {
di.annotate(classFunc, new di.Provide(targetClassFunc));
};
}
exports.Provide = Provide;
//# sourceMappingURL=index.js.map

@@ -1,2 +0,1 @@

/// <reference path="./di.d.ts"/>

@@ -7,22 +6,19 @@

declare var Reflect: any;
declare
var Reflect: any;
module diTS {
export var Injector = di.Injector;
export var Injector = di.Injector;
export function Inject(classFunc: any) {
const dependencies = Reflect.getMetadata("design:paramtypes", classFunc) || [];
(<any>di).annotate.apply(di, [classFunc].concat(dependencies.map((dep: any) => new (<any>di).Inject(dep))));
}
export function Inject(classFunc: any) {
const dependencies = Reflect.getMetadata("design:paramtypes", classFunc) || [];
(<any>di).annotate.apply(di, [classFunc].concat(dependencies.map((dep: any) => new (<any>di).Inject(dep))));
}
export function Provide(targetClassFunc: any) {
return function (classFunc: any) {
(<any>di).annotate(classFunc, new (<any>di).Provide(targetClassFunc));
};
}
export function Provide(targetClassFunc: any) {
return function (classFunc: any) {
(<any>di).annotate(classFunc, new (<any>di).Provide(targetClassFunc));
};
}
export = diTS;
{
"name": "di-ts",
"version": "0.0.9",
"version": "0.0.10",
"description": "Lightweight wrap and extension of angular/di.js for TypeScript.",

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

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