mongoose-simple-random: Convert to external module (#20083)

This commit is contained in:
Andy
2017-09-27 13:26:14 -07:00
committed by Mohamed Hegazy
parent aca6775acc
commit e2ac4b9aa4

View File

@@ -1,17 +1,12 @@
// Type definitions for mongoose-simple-random 0.4
// Project: https://github.com/larryprice/mongoose-simple-random
// Definitions by: My Self <https://github.com/me>
// Definitions by: Roberts Slisans <https://github.com/rsxdalv>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
declare module 'mongoose-simple-random' {
import mongoose = require('mongoose');
// Dummy function allows to avoid hard to kill or fix tslint warning
// (exporting pluginFunc will make this a non-importable module)
function pluginFunc(schema: mongoose.Schema): void;
// Let allows typescript to still use ES2015 style imports
let plugin: typeof pluginFunc;
export = plugin;
}
import mongoose = require('mongoose');
declare function pluginFunc(schema: mongoose.Schema): void;
declare namespace pluginFunc {}
export = pluginFunc;
declare module "mongoose" {
interface Model<T extends Document> extends NodeJS.EventEmitter, ModelProperties {