fix(medusa-react): Fix production.min.js causing invalid hook usage error in CJS environments (#3144)
This commit is contained in:
@@ -2,52 +2,36 @@
|
||||
"version": "4.0.3",
|
||||
"license": "MIT",
|
||||
"main": "dist/index.js",
|
||||
"typings": "dist/index.d.ts",
|
||||
"files": [
|
||||
"dist",
|
||||
"src"
|
||||
],
|
||||
"module": "dist/index.mjs",
|
||||
"types": "dist/index.d.ts",
|
||||
"exports": {
|
||||
".": {
|
||||
"import": "./dist/index.mjs",
|
||||
"require": "./dist/index.js"
|
||||
},
|
||||
"./package.json": "./package.json"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=10"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "dts watch",
|
||||
"build": "dts build",
|
||||
"prepare": "dts build",
|
||||
"test": "dts test --passWithNoTests",
|
||||
"lint": "dts lint",
|
||||
"size": "size-limit",
|
||||
"analyze": "size-limit --why",
|
||||
"build": "tsup src/index.ts",
|
||||
"prepare": "cross-env NODE_ENV=production yarn run build",
|
||||
"storybook": "start-storybook -p 6006 -s public",
|
||||
"build-storybook": "build-storybook"
|
||||
"build-storybook": "build-storybook",
|
||||
"test": "jest --passWithNoTests"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"@medusajs/medusa": "^1.7.4",
|
||||
"@tanstack/react-query": ">=4.22.0",
|
||||
"react": ">=16"
|
||||
},
|
||||
"husky": {
|
||||
"hooks": {
|
||||
"pre-commit": "tsdx lint"
|
||||
}
|
||||
"react": ">=16",
|
||||
"react-dom": ">=16"
|
||||
},
|
||||
"name": "medusa-react",
|
||||
"author": "Zakaria S. El Asri",
|
||||
"module": "dist/medusa-react.esm.js",
|
||||
"size-limit": [
|
||||
{
|
||||
"path": "dist/medusa-react.cjs.production.min.js",
|
||||
"limit": "10 KB"
|
||||
},
|
||||
{
|
||||
"path": "dist/medusa-react.esm.js",
|
||||
"limit": "10 KB"
|
||||
}
|
||||
],
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.16.0",
|
||||
"@medusajs/medusa": "^1.7.4",
|
||||
"@size-limit/preset-small-lib": "^6.0.4",
|
||||
"@storybook/addon-contexts": "^5.3.21",
|
||||
"@storybook/addon-essentials": "^6.3.12",
|
||||
"@storybook/addon-info": "^5.3.21",
|
||||
@@ -55,30 +39,28 @@
|
||||
"@storybook/addons": "^6.3.12",
|
||||
"@storybook/react": "^6.3.12",
|
||||
"@tanstack/react-query": "^4.22.0",
|
||||
"@testing-library/react": "^12.1.2",
|
||||
"@testing-library/react-hooks": "^7.0.2",
|
||||
"@testing-library/react": "^13.4.0",
|
||||
"@testing-library/react-hooks": "^8.0.1",
|
||||
"@types/jest": "^27.0.3",
|
||||
"@types/lodash": "^4.14.177",
|
||||
"@types/react": "^17.0.33",
|
||||
"@types/react-dom": "^17.0.10",
|
||||
"axios": "^0.24.0",
|
||||
"babel-loader": "^8.2.3",
|
||||
"dts-cli": "^1.5.1",
|
||||
"husky": "^7.0.4",
|
||||
"cross-env": "^7.0.3",
|
||||
"jest": "^29.4.1",
|
||||
"jest-environment-jsdom": "^29.4.1",
|
||||
"msw": "^0.35.0",
|
||||
"msw-storybook-addon": "^1.5.0",
|
||||
"react": "^17.0.2",
|
||||
"react-dom": "^17.0.2",
|
||||
"react-is": "^17.0.2",
|
||||
"react-json-view": "^1.21.3",
|
||||
"size-limit": "^6.0.4",
|
||||
"ts-jest": "^27.1.4",
|
||||
"tslib": "^2.3.1"
|
||||
"ts-jest": "^29.0.5",
|
||||
"tslib": "^2.3.1",
|
||||
"tsup": "^6.5.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@medusajs/medusa-js": "^1.3.7",
|
||||
"lodash": "^4.17.21",
|
||||
"lodash-es": "^4.17.21"
|
||||
"@medusajs/medusa-js": "^1.3.7"
|
||||
},
|
||||
"msw": {
|
||||
"workerDirectory": "public"
|
||||
|
||||
Reference in New Issue
Block a user