From 0d0dc6525ce6fbad64ac4c4c7f8c49047aa9a710 Mon Sep 17 00:00:00 2001 From: asins Date: Fri, 21 Apr 2023 12:18:41 +0800 Subject: [PATCH] feat: add typings attr to package.json --- index.js | 2 +- package.json | 3 ++- rollup.config.js | 1 + 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index 77968ae..b534604 100644 --- a/index.js +++ b/index.js @@ -103,4 +103,4 @@ deepmerge.all = function deepmergeAll(array, options) { }, {}) } -module.exports = deepmerge +export default deepmerge; diff --git a/package.json b/package.json index 7926106..89fb1f7 100644 --- a/package.json +++ b/package.json @@ -9,7 +9,7 @@ "clone", "recursive" ], - "version": "4.3.1", + "version": "4.3.2", "homepage": "https://github.com/TehShrike/deepmerge", "repository": { "type": "git", @@ -17,6 +17,7 @@ }, "main": "dist/deepmerge.cjs.js", "module": "dist/deepmerge.esm.js", + "typings": "index.d.ts", "engines": { "node": ">=0.10.0" }, diff --git a/rollup.config.js b/rollup.config.js index 4695836..39e4413 100644 --- a/rollup.config.js +++ b/rollup.config.js @@ -12,6 +12,7 @@ export default { { name: 'deepmerge', file: pkg.main, + exports: 'named', format: `cjs` }, {