I have a next js project for a while. For sometime the build is ok, until I clean install the node module from scratch.
Now I got an error when ever try to build.
ModuleNotFoundError: Module not found: Error: Package path ./lib/enums is not exported from package {PROEJCT_PATH}\node_modules@popperjs\core (see exports field in {PROEJCT_PATH}\node_modules@popperjs\core\package.json)
Does anyone know what could be the issue here?
here are my package json
package json main project
{
"name": "my-project",
"version": "0.0.1",
"description": "TODO: Give a short introduction of your project. Let this section explain the objectives or the motivation behind this project.",
"main": "server.js",
"scripts": {
"test": "jest",
"test:ci": "jest --ci",
"local": "next dev -p 2001",
"dev": "node server.js",
"build": "npx next telemetry disable && next build",
"start": "NODE_ENV=production node server.js",
"start_local": "node server.js",
"ri": "npm install && npm run dev",
"u-lib": "npm remove vesta-vnext-react-library"
},
"keywords": [],
"author": "Shopify",
"license": "MIT",
"bugs": {
"url": "https://github.com/Shopify/shopify-demo-app-node-react/issues"
},
"homepage": "https://github.com/Shopify/shopify-demo-app-node-react#readme",
"dependencies": {
"-": "0.0.1",
"@azure/identity": "1.3.0",
"@azure/msal-browser": "2.15.0",
"@azure/msal-react": "1.0.0",
"@azure/storage-blob": "^12.5.0",
"@fortawesome/fontawesome-free": "5.15.1",
"@koa/cors": "3.1.0",
"@material-ui/core": "4.11.2",
"@material-ui/data-grid": "4.0.0-alpha.23",
"@material-ui/icons": "4.11.2",
"@material-ui/lab": "4.0.0-alpha.57",
"@react-google-maps/api": "1.13.0",
"D": "1.0.0",
"async-retry": "1.3.1",
"axios": "^0.21.1",
"babel-preset-es2015": "^6.24.1",
"bootstrap": "^5.0.1",
"clsx": "1.1.1",
"dotenv": "8.2.0",
"enzyme": "3.11.0",
"filter-objects": "2.1.1",
"form-data": "^4.0.0",
"formidable": "^1.2.2",
"g": "2.0.1",
"hamburger-react": "2.4.0",
"isomorphic-fetch": "3.0.0",
"joi": "17.4.0",
"joi-password-complexity": "5.1.0",
"jquery": "3.6.0",
"js-cookie": "2.2.1",
"koa": "2.13.0",
"koa-router": "10.0.0",
"koa-session": "6.1.0",
"lodash": "4.17.21",
"lodash-es": "4.17.21",
"map": "1.0.1",
"material-table": "1.57.2",
"moment": "2.29.1",
"msal": "1.4.4",
"next": "^11.1.2",
"next-compose-plugins": "^2.2.1",
"next-transpile-modules": "^8.0.0",
"nextjs-cors": "^1.0.5",
"papaparse": "^5.3.1",
"powerbi-client-react": "1.3.0",
"progressbar.js": "1.1.0",
"react": "^17.0.2",
"react-bootstrap": "1.4.0",
"react-circular-progressbar": "2.0.4",
"react-cookie": "4.0.3",
"react-csv": "^2.0.3",
"react-d3-speedometer": "1.0.1",
"react-dom": "^17.0.2",
"react-draggable": "4.4.3",
"react-dropzone": "11.3.2",
"react-helmet": "6.1.0",
"react-hook-form": "6.14.1",
"react-icons": "4.1.0",
"react-idle-timer": "4.5.4",
"react-pro-sidebar": "0.4.4",
"react-select": "4.3.0",
"sass": "1.29.0",
"store-js": "2.0.4",
"tmp": "^0.2.1",
"my-library": "file:my-library-0.5.0.tgz"
},
"devDependencies": {
"@babel/preset-env": "^7.14.2",
"@babel/preset-react": "^7.13.13",
"@testing-library/jest-dom": "5.11.10",
"@testing-library/react": "11.2.6",
"@testing-library/user-event": "13.1.3",
"@types/jquery": "3.5.5",
"@types/lodash": "4.14.168",
"@types/node": "14.14.10",
"@types/react-csv": "^1.1.2",
"@types/react-test-renderer": "17.0.1",
"@typescript-eslint/eslint-plugin": "4.14.0",
"@typescript-eslint/parser": "4.14.0",
"babel-jest": "26.6.3",
"eslint": "5.16.0",
"eslint-plugin-react": "7.21.5",
"identity-obj-proxy": "3.0.0",
"jest": "26.6.3",
"jest-ts-auto-mock": "2.0.0",
"next-page-tester": "0.24.1",
"react-date-range": "^1.1.3",
"react-test-renderer": "17.0.2",
"ts-auto-mock": "3.1.2",
"ts-jest": "26.5.5",
"ttypescript": "1.5.12",
"typescript": "^4.4.2"
},
"directories": {
"test": "test"
}
}
package json my-library
{
"name": "my-library",
"version": "0.5.0",
"description": "A library that has usable components for vNext project",
"main": "dist/index.js",
"module": "dist/index.js",
"private": true,
"dependencies": {
"@azure/storage-blob": "12.5.0",
"@date-io/moment": "1.3.13",
"@fortawesome/fontawesome-svg-core": "1.2.35",
"@fortawesome/free-solid-svg-icons": "5.15.3",
"@fortawesome/react-fontawesome": "0.1.14",
"@material-ui/core": "4.11.2",
"@material-ui/icons": "4.11.2",
"@material-ui/pickers": "3.3.10",
"@rollup/plugin-json": "^4.1.0",
"@rollup/plugin-node-resolve": "13.0.0",
"@types/react-phone-number-input": "3.0.7",
"bootstrap": "5.0.1",
"jquery": "3.6.0",
"lodash": "4.17.21",
"moment": "2.29.1",
"papaparse": "5.3.1",
"precss": "4.0.0",
"react-circular-progressbar": "2.0.4",
"react-data-table-component": "6.11.5",
"react-date-range": "1.1.3",
"react-dropzone": "11.3.2",
"react-helmet": "6.1.0",
"react-phone-input": "^1.2.1",
"react-phone-input-2": "^2.14.0",
"react-phone-number-input": "^3.1.25",
"styled-components": "5.0.1"
},
"peerDependencies": {
"@azure/storage-blob": "12.5.0",
"@material-ui/core": "4.11.2",
"@date-io/moment": "1.3.13",
"@material-ui/icons": "4.11.2",
"@rollup/plugin-node-resolve": "13.0.0",
"precss": "4.0.0",
"react-dropzone": "11.3.2",
"moment": "2.29.1",
"react-bootstrap": "1.6.0",
"react-helmet": "6.1.0",
"react-date-range": "1.1.3",
"react-data-table-component": "6.11.5",
"styled-components": "5.0.1"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"ts-build": "tsc --project ./ --module commonjs",
"b-lib": "rollup -c && npm pack",
"test": "react-scripts test",
"eject": "react-scripts eject",
"storybook": "start-storybook -p 6006 -s public",
"build-storybook": "build-storybook -s public"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
],
"overrides": [
{
"files": [
"**/*.stories.*"
],
"rules": {
"import/no-anonymous-default-export": "off"
}
}
]
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"@babel/preset-env": "7.14.2",
"@babel/preset-react": "7.13.13",
"@material-ui/lab": "4.0.0-alpha.57",
"@rollup/plugin-commonjs": "19.0.0",
"@rollup/plugin-image": "2.0.6",
"@rollup/plugin-typescript": "8.2.1",
"@storybook/addon-actions": "6.2.9",
"@storybook/addon-essentials": "6.2.9",
"@storybook/addon-links": "6.2.9",
"@storybook/node-logger": "6.2.9",
"@storybook/preset-create-react-app": "3.1.7",
"@storybook/react": "6.2.9",
"@testing-library/jest-dom": "5.11.4",
"@testing-library/react": "11.1.0",
"@testing-library/user-event": "12.1.10",
"@types/jest": "26.0.15",
"@types/jquery": "^3.5.6",
"@types/lodash": "4.14.170",
"@types/node": "12.0.0",
"@types/react": "17.0.0",
"@types/react-dom": "17.0.0",
"autoprefixer": "10.2.6",
"axios": "0.21.1",
"date-fns": "2.0.0-beta.5",
"moment": "2.29.1",
"postcss": "8.3.0",
"postcss-import": "14.0.2",
"react": "17.0.2",
"react-advanced-form": "1.7.2",
"react-advanced-form-addons": "1.3.3",
"react-bootstrap": "1.6.0",
"react-checkbox-tree": "1.6.0",
"react-data-table-component": "6.11.5",
"react-date-range": "1.1.3",
"react-dom": "17.0.2",
"react-helmet": "6.1.0",
"react-scripts": "4.0.3",
"rollup": "2.50.0",
"rollup-plugin-babel": "4.4.0",
"rollup-plugin-import-css": "2.0.1",
"rollup-plugin-peer-deps-external": "2.2.4",
"rollup-plugin-postcss": "4.0.0",
"rollup-plugin-scss": "2.6.1",
"rollup-plugin-terser": "7.0.2",
"rollup-plugin-typescript2": "0.30.0",
"tsc": "2.0.3",
"tslib": "2.2.0",
"typescript": "4.2.4",
"web-vitals": "1.0.1"
},
"typings": "dist/index.d.ts",
"typescript": {
"definition": "dist/index.d.ts",
"reactDocgen": "none"
},
"repository": {
"type": "git",
"url": "__"
}
}