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

moize

Package Overview
Dependencies
Maintainers
2
Versions
104
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

moize - npm Package Compare versions

Comparing version 5.3.2 to 5.4.0

js-to-mjs.js

4

CHANGELOG.md
# moize CHANGELOG
## 5.4.0
- Add ESM support for NodeJS with separate [`.mjs` extension](https://nodejs.org/api/esm.html) exports
## 5.3.2

@@ -4,0 +8,0 @@

5

dist/moize.js

@@ -1223,3 +1223,6 @@ (function (global, factory) {

var toPairs = function toPairs(iterable) {
var pairs = { keys: [], values: [] };
var pairs = {
keys: [],
values: []
};

@@ -1226,0 +1229,0 @@ iterable.forEach(function (value, key) {

@@ -37,5 +37,5 @@ {

"dependencies": {
"fast-equals": "^1.5.3",
"fast-stringify": "^1.0.4",
"micro-memoize": "^2.0.4"
"fast-equals": "^1.6.0",
"fast-stringify": "^1.1.0",
"micro-memoize": "^2.1.0"
},

@@ -67,2 +67,3 @@ "description": "Blazing fast memoization based on all parameters passed",

"flow-bin": "^0.78.0",
"fs-extra": "^7.0.0",
"html-webpack-plugin": "^3.2.0",

@@ -90,8 +91,8 @@ "husky": "^0.14.3",

"rimraf": "^2.6.2",
"rollup": "^0.63.5",
"rollup": "^0.64.1",
"rollup-plugin-babel": "^3.0.7",
"rollup-plugin-commonjs": "^9.1.4",
"rollup-plugin-commonjs": "^9.1.5",
"rollup-plugin-node-resolve": "^3.3.0",
"rollup-plugin-uglify": "^4.0.0",
"sinon": "^6.1.4",
"sinon": "^6.1.5",
"underscore": "^1.9.1",

@@ -126,3 +127,3 @@ "webpack": "^4.16.5",

"build": "NODE_ENV=production rollup -c",
"clean": "npm run clean:lib && npm run clean:es && npm run clean:dist && npm run clean:docs",
"clean": "npm run clean:lib && npm run clean:es && npm run clean:dist && npm run clean:mjs && npm run clean:docs",
"clean:dist": "rimraf dist",

@@ -132,2 +133,3 @@ "clean:docs": "rimraf docs",

"clean:lib": "rimraf lib",
"clean:mjs": "rimraf mjs",
"dev": "NODE_ENV=development webpack-dev-server --colors --progress --config=webpack/webpack.config.js",

@@ -141,3 +143,4 @@ "dist": "npm run clean:dist && npm run build",

"prepublish": "if in-publish; then npm run prepublish:compile; fi",
"prepublish:compile": "npm run lint && npm run flow && npm run test:coverage && npm run transpile:lib && npm run transpile:es && npm run dist",
"prepublish:compile": "npm run lint && npm run flow && npm run test:coverage && npm run transpile:lib && npm run transpile:es && npm run transpile:mjs && npm run rename:mjs && npm run dist",
"rename:mjs": "node ./js-to-mjs.js",
"start": "npm run dev",

@@ -148,6 +151,7 @@ "test": "NODE_PATH=. NODE_ENV=production BABEL_ENV=test ava",

"transpile:es": "npm run clean:es && BABEL_ENV=es babel src --out-dir es",
"transpile:lib": "npm run clean:lib && BABEL_ENV=lib babel src --out-dir lib"
"transpile:lib": "npm run clean:lib && BABEL_ENV=lib babel src --out-dir lib",
"transpile:mjs": "npm run clean:mjs && BABEL_ENV=mjs babel src --out-dir mjs"
},
"types": "./index.d.ts",
"version": "5.3.2"
"version": "5.4.0"
}

@@ -12,2 +12,3 @@ # moize

- [Installation](#installation)
- [Importing](#importing)
- [Usage](#usage)

@@ -72,2 +73,22 @@ - [Configuration options](#configuration-options)

## Importing
ESM syntax in browsers:
```javascript
import moize from "moize";
```
ESM syntax in NodeJS:
```javascript
import moize from "moize/mjs";
```
CommonJS:
```javascript
const moize = require("moize").default;
```
## Usage

@@ -74,0 +95,0 @@

Sorry, the diff of this file is not supported yet

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