Comparing version 4.0.0-rc2 to 4.0.0-rc3
@@ -213,3 +213,39 @@ 'use strict'; | ||
module.exports = Object.assign({}, constants, { | ||
module.exports = { | ||
// constants | ||
// NOTE: this is done this way because rollup can't resolve an `Object.assign`ed export | ||
BSON_INT32_MAX: constants.BSON_INT32_MAX, | ||
BSON_INT32_MIN: constants.BSON_INT32_MIN, | ||
BSON_INT64_MAX: constants.BSON_INT64_MAX, | ||
BSON_INT64_MIN: constants.BSON_INT64_MIN, | ||
JS_INT_MAX: constants.JS_INT_MAX, | ||
JS_INT_MIN: constants.JS_INT_MIN, | ||
BSON_DATA_NUMBER: constants.BSON_DATA_NUMBER, | ||
BSON_DATA_STRING: constants.BSON_DATA_STRING, | ||
BSON_DATA_OBJECT: constants.BSON_DATA_OBJECT, | ||
BSON_DATA_ARRAY: constants.BSON_DATA_ARRAY, | ||
BSON_DATA_BINARY: constants.BSON_DATA_BINARY, | ||
BSON_DATA_UNDEFINED: constants.BSON_DATA_UNDEFINED, | ||
BSON_DATA_OID: constants.BSON_DATA_OID, | ||
BSON_DATA_BOOLEAN: constants.BSON_DATA_BOOLEAN, | ||
BSON_DATA_DATE: constants.BSON_DATA_DATE, | ||
BSON_DATA_NULL: constants.BSON_DATA_NULL, | ||
BSON_DATA_REGEXP: constants.BSON_DATA_REGEXP, | ||
BSON_DATA_DBPOINTER: constants.BSON_DATA_DBPOINTER, | ||
BSON_DATA_CODE: constants.BSON_DATA_CODE, | ||
BSON_DATA_SYMBOL: constants.BSON_DATA_SYMBOL, | ||
BSON_DATA_CODE_W_SCOPE: constants.BSON_DATA_CODE_W_SCOPE, | ||
BSON_DATA_INT: constants.BSON_DATA_INT, | ||
BSON_DATA_TIMESTAMP: constants.BSON_DATA_TIMESTAMP, | ||
BSON_DATA_LONG: constants.BSON_DATA_LONG, | ||
BSON_DATA_DECIMAL128: constants.BSON_DATA_DECIMAL128, | ||
BSON_DATA_MIN_KEY: constants.BSON_DATA_MIN_KEY, | ||
BSON_DATA_MAX_KEY: constants.BSON_DATA_MAX_KEY, | ||
BSON_BINARY_SUBTYPE_DEFAULT: constants.BSON_BINARY_SUBTYPE_DEFAULT, | ||
BSON_BINARY_SUBTYPE_FUNCTION: constants.BSON_BINARY_SUBTYPE_FUNCTION, | ||
BSON_BINARY_SUBTYPE_BYTE_ARRAY: constants.BSON_BINARY_SUBTYPE_BYTE_ARRAY, | ||
BSON_BINARY_SUBTYPE_UUID: constants.BSON_BINARY_SUBTYPE_UUID, | ||
BSON_BINARY_SUBTYPE_MD5: constants.BSON_BINARY_SUBTYPE_MD5, | ||
BSON_BINARY_SUBTYPE_USER_DEFINED: constants.BSON_BINARY_SUBTYPE_USER_DEFINED, | ||
// wrapped types | ||
@@ -244,2 +280,2 @@ Code, | ||
EJSON | ||
}); | ||
}; |
@@ -116,3 +116,3 @@ 'use strict'; | ||
* @example | ||
* const EJSON = require('mongodb-extjson'); | ||
* const { EJSON } = require('bson'); | ||
* const text = '{ "int32": { "$numberInt": "10" } }'; | ||
@@ -160,3 +160,3 @@ * | ||
* @example | ||
* const EJSON = require('mongodb-extjson'); | ||
* const { EJSON } = require('bson'); | ||
* const Int32 = require('mongodb').Int32; | ||
@@ -163,0 +163,0 @@ * const doc = { int32: new Int32(10) }; |
@@ -14,3 +14,3 @@ { | ||
], | ||
"version": "4.0.0-rc2", | ||
"version": "4.0.0-rc3", | ||
"author": "Christian Amor Kvalheim <christkv@gmail.com>", | ||
@@ -17,0 +17,0 @@ "license": "Apache-2.0", |
@@ -122,3 +122,3 @@ # BSON parser | ||
```js | ||
const EJSON = require('mongodb-extjson'); | ||
const { EJSON } = require('bson'); | ||
const text = '{ "int32": { "$numberInt": "10" } }'; | ||
@@ -150,3 +150,3 @@ | ||
```js | ||
const EJSON = require('mongodb-extjson'); | ||
const { EJSON } = require('bson'); | ||
const Int32 = require('mongodb').Int32; | ||
@@ -153,0 +153,0 @@ const doc = { int32: new Int32(10) }; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
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
933008
24396