refactor: convert to cjs
This commit is contained in:
parent
0abf7f5633
commit
534ba472a8
12
index.js
12
index.js
|
@ -1,10 +1,10 @@
|
||||||
export default function pDefer() {
|
exports = function pDefer () {
|
||||||
const deferred = {};
|
const deferred = {}
|
||||||
|
|
||||||
deferred.promise = new Promise((resolve, reject) => {
|
deferred.promise = new Promise((resolve, reject) => {
|
||||||
deferred.resolve = resolve;
|
deferred.resolve = resolve
|
||||||
deferred.reject = reject;
|
deferred.reject = reject
|
||||||
});
|
})
|
||||||
|
|
||||||
return deferred;
|
return deferred
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,7 +10,6 @@
|
||||||
"email": "sindresorhus@gmail.com",
|
"email": "sindresorhus@gmail.com",
|
||||||
"url": "https://sindresorhus.com"
|
"url": "https://sindresorhus.com"
|
||||||
},
|
},
|
||||||
"type": "module",
|
|
||||||
"exports": "./index.js",
|
"exports": "./index.js",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
|
|
Loading…
Reference in New Issue