Socket
Socket
Sign inDemoInstall

@brickyang/easy-mongodb

Package Overview
Dependencies
21
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.1.0 to 1.1.1

41

index.d.ts

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

import EventEmitter from 'events';
import * as EventEmitter from 'events';
import {

@@ -24,3 +24,2 @@ Collection,

MongoClient,
FindOneOptions,
SessionOptions,

@@ -36,2 +35,3 @@ ClientSession,

declare class MongoDB {
public config: IMongoConfig;
private url: string;

@@ -41,3 +41,2 @@ private clientOptions: MongoClientOptions;

public client: MongoClient;
public config: IMongoConfig;
public featureCompatibilityVersion: string;

@@ -47,7 +46,9 @@

public connect(url: string): Promise<Db>;
public connect(): Promise<MongoClient>;
public close(): Promise<void>;
public insertOne(
name: string,
args?: { doc: Object; options?: CollectionInsertOneOptions }
args: { doc: Object; options?: CollectionInsertOneOptions }
): Promise<InsertOneWriteOpResult>;

@@ -57,3 +58,3 @@

name: string,
args?: { docs: Object[]; options?: CollectionInsertManyOptions }
args: { docs: Object[]; options?: CollectionInsertManyOptions }
): Promise<InsertWriteOpResult>;

@@ -122,3 +123,3 @@

},
returnCursor: boolean
returnCursor: true
): Promise<Cursor<T>>;

@@ -136,5 +137,9 @@

options?: FindOneOptions;
}
},
returnCursor?: boolean
): Promise<T[]>;
/**
* @deprecated Use `countDocuments` or `estimatedDocumentCount` instead
*/
public count(

@@ -148,5 +153,21 @@ name: string,

public distinct(
public countDocuments(
name: string,
args: {
query?: any;
options?: MongoCountPreferences;
}
): Promise<number>;
public estimatedDocumentCount(
name: string,
args?: {
query?: any;
options?: MongoCountPreferences;
}
): Promise<number>;
public distinct<T = Default>(
name: string,
args: {
key: string;

@@ -160,3 +181,3 @@ query?: Object;

}
): Promise<any[]>;
): Promise<T[]>;

@@ -163,0 +184,0 @@ public createIndex(

@@ -654,3 +654,3 @@ 'use strict';

* @param {object} args
* @param {object} args.options - Options for the transaction
* @param {object} [args.options] - Options for the transaction
*

@@ -657,0 +657,0 @@ * @return {object} clientSeesion

{
"name": "@brickyang/easy-mongodb",
"version": "1.1.0",
"version": "1.1.1",
"description": "Based on MongoDB Native Node.js Driver.",

@@ -19,4 +19,13 @@ "main": "index.js",

"mocha": "^5.2.0",
"nyc": "^13.1.0"
"nyc": "^13.1.0",
"tslint": "^5.12.1"
},
"files": [
"lib",
"index.js",
"index.d.ts"
],
"keywords": [
"mongodb"
],
"repository": {

@@ -26,11 +35,8 @@ "type": "git",

},
"keywords": [
"mongodb"
],
"author": "Brick",
"license": "MIT",
"bugs": {
"url": "https://github.com/brickyang/easy-mongodb/issues"
},
"homepage": "https://github.com/brickyang/easy-mongodb#readme"
"homepage": "https://github.com/brickyang/easy-mongodb#readme",
"author": "Brick",
"license": "MIT"
}
SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc