marmelab / react-admin

A frontend Framework for single-page applications on top of REST/GraphQL APIs, using TypeScript, React and Material Design
http://marmelab.com/react-admin
MIT License
24.85k stars 5.23k forks source link

Simple example doesn't start #5438

Closed msteingruber closed 3 years ago

msteingruber commented 3 years ago

What you were expecting: Step-by-step:

  1. Checkout master branch of react-admin
  2. yarn command in examples/simple
  3. yarn dev command in examples/simple
  4. Running application

What happened instead:

yarn-Output:

➜ simple git:(master) ✗ yarn yarn install v1.22.4 [1/4] 🔍 Resolving packages... [2/4] 🚚 Fetching packages... [3/4] 🔗 Linking dependencies... warning " > eslint-config-react-app@5.2.1" has incorrect peer dependency "@typescript-eslint/eslint-plugin@2.x". warning " > eslint-config-react-app@5.2.1" has incorrect peer dependency "@typescript-eslint/parser@2.x". warning " > eslint-config-react-app@5.2.1" has incorrect peer dependency "eslint@6.x". warning " > eslint-config-react-app@5.2.1" has incorrect peer dependency "eslint-plugin-flowtype@3.x || 4.x". warning " > eslint-config-react-app@5.2.1" has incorrect peer dependency "eslint-plugin-react-hooks@1.x || 2.x". warning " > ra-core@3.9.4" has unmet peer dependency "connected-react-router@^6.5.2". warning " > ra-core@3.9.4" has unmet peer dependency "final-form@^4.18.5". warning " > ra-core@3.9.4" has unmet peer dependency "react@^16.9.0". warning " > ra-core@3.9.4" has unmet peer dependency "react-dom@^16.9.0". warning " > ra-core@3.9.4" has unmet peer dependency "react-final-form@^6.3.3". warning " > ra-core@3.9.4" has unmet peer dependency "react-redux@^7.1.0". warning " > ra-core@3.9.4" has unmet peer dependency "react-router@^5.1.0". warning " > ra-core@3.9.4" has unmet peer dependency "react-router-dom@^5.1.0". warning " > ra-core@3.9.4" has unmet peer dependency "redux@^3.7.2 || ^4.0.3". warning " > ra-core@3.9.4" has unmet peer dependency "redux-saga@^1.0.0". warning " > ra-data-graphql-simple@3.9.2" has unmet peer dependency "graphql@^14.1.1". warning " > ra-data-graphql@3.9.2" has unmet peer dependency "graphql@^14.1.1". warning " > ra-input-rich-text@3.9.1" has unmet peer dependency "react@^16.9.0". warning " > ra-input-rich-text@3.9.1" has unmet peer dependency "react-dom@^16.9.0". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "@material-ui/core@^4.3.3". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "@material-ui/icons@^4.2.1". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "@material-ui/styles@^4.3.3". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "final-form@^4.18.5". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "final-form-arrays@^3.0.1". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "react@^16.9.0". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "react-dom@^16.9.0". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "react-final-form@^6.3.3". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "react-final-form-arrays@^3.1.1". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "react-redux@^7.1.0". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "react-router@^5.1.0". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "react-router-dom@^5.1.0". warning " > ra-ui-materialui@3.9.4" has unmet peer dependency "redux@^3.7.2 || ^4.0.3". warning " > react-admin@3.9.4" has unmet peer dependency "react@^16.9.0". warning " > react-admin@3.9.4" has unmet peer dependency "react-dom@^16.9.0". warning "workspace-aggregator-79fbfe3b-f2c5-40eb-bc73-0942717968f3 > ra-data-graphql-simple > graphql-ast-types-browser@1.0.2" has incorrect peer dependency "graphql@^0.11.7". warning "workspace-aggregator-79fbfe3b-f2c5-40eb-bc73-0942717968f3 > e2e > @cypress/webpack-preprocessor@5.4.5" has unmet peer dependency "@babel/core@^7.0.1". warning "workspace-aggregator-79fbfe3b-f2c5-40eb-bc73-0942717968f3 > e2e > @cypress/webpack-preprocessor@5.4.5" has unmet peer dependency "@babel/preset-env@^7.0.0". warning "workspace-aggregator-79fbfe3b-f2c5-40eb-bc73-0942717968f3 > e2e > @cypress/webpack-preprocessor@5.4.5" has unmet peer dependency "babel-loader@^8.0.2". warning "workspace-aggregator-79fbfe3b-f2c5-40eb-bc73-0942717968f3 > e2e > @cypress/webpack-preprocessor@5.4.5" has unmet peer dependency "webpack@^4.18.1". warning "workspace-aggregator-79fbfe3b-f2c5-40eb-bc73-0942717968f3 > demo > json-graphql-server > graphql-tag@2.0.0" has incorrect peer dependency "graphql@^0.9.x". warning "workspace-aggregator-79fbfe3b-f2c5-40eb-bc73-0942717968f3 > demo > react-scripts > eslint-config-react-app@5.2.0" has incorrect peer dependency "eslint-plugin-flowtype@3.x". [4/4] 🔨 Building fresh packages... warning Your current version of Yarn is out of date. The latest version is "1.22.5", while you're on "1.22.4". info To upgrade, run the following command: $ curl --compressed -o- -L https://yarnpkg.com/install.sh | bash ✨ Done in 228.74s.

yarn dev-Output:

`yarn run v1.22.4 $ ./node_modules/.bin/webpack-dev-server --progress --color --hot --watch --mode development 10% building modules 1/1 modules 0 activeℹ 「wds」: Project is running at http://127.0.0.1:8080/ ℹ 「wds」: webpack output is served from / 11% building modules 16/20 modules 4 active …de_modules/sockjs-client/dist/sockjs.js WARNING: We noticed you're using the useBuiltIns option without declaring a core-js version. Currently, we assume version 2.x when no version is passed. Since this default version will likely change in future versions of Babel, we recommend explicitly setting the core-js version you are using via the corejs option.

You should also be sure that the version you pass to the corejs option matches the version specified in your package.json's dependencies section. If it doesn't, you need to run one of the following commands:

npm install --save core-js@2 npm install --save core-js@3 yarn add core-js@2 yarn add core-js@3 ✖ 「wdm」: Hash: 8227638cdb3c5fadbb60 Version: webpack 4.5.0 Time: 14583ms Built at: 10/24/2020 9:47:12 AM Asset Size Chunks Chunk Names main.js 4.17 MiB main [emitted] main 0.js 4.19 KiB 0 [emitted]
main.js.map 3.69 MiB main [emitted] main 0.js.map 2.77 KiB 0 [emitted]
index.html 603 bytes [emitted]
Entrypoint main = main.js main.js.map

ERROR in ./src/dataProvider.js Module not found: Error: Can't resolve 'ra-data-fakerest' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src' @ ./src/dataProvider.js 1:0-48 5:21-37 @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/i18nProvider.js Module not found: Error: Can't resolve 'ra-i18n-polyglot' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src' @ ./src/i18nProvider.js 1:0-52 6:15-35 @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/posts/PostEdit.js Module not found: Error: Can't resolve 'ra-input-rich-text' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/posts' @ ./src/posts/PostEdit.js 10:0-47 111:38-51 @ ./src/posts/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/posts/PostCreate.js Module not found: Error: Can't resolve 'ra-input-rich-text' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/posts' @ ./src/posts/PostCreate.js 18:0-47 93:39-52 @ ./src/posts/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/i18n/en.js Module not found: Error: Can't resolve 'ra-language-english' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/i18n' @ ./src/i18n/en.js 10:0-50 19:3-18 @ ./src/i18nProvider.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/i18n/fr.js Module not found: Error: Can't resolve 'ra-language-french' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/i18n' @ ./src/i18n/fr.js 10:0-48 19:3-17 @ ./src/i18nProvider.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/index.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src' @ ./src/index.js 5:0-46 19:41-46 35:52-60 37:45-53 39:62-70 41:52-60 @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/customRouteLayout.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src' @ ./src/customRouteLayout.js 2:0-66 5:2-18 11:6-16 18:97-102 @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/customRouteNoLayout.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src' @ ./src/customRouteNoLayout.js 4:0-42 11:13-24 @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/dataProvider.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src' @ ./src/dataProvider.js 2:0-53 23:15-37 @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/Layout.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src' @ ./src/Layout.js 5:0-80 18:17-26 19:20-32 33:61-69 35:59-65 39:58-64 @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/comments/index.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/comments' @ ./src/comments/index.js 5:0-42 10:8-19 @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/comments/CommentEdit.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/comments' @ ./src/comments/CommentEdit.js 5:0-154 11:42-46 48:6-23 51:38-43 55:38-49 63:48-58 70:38-47 74:39-53 83:38-55 90:99-108 92:14-23 94:39-48 97:39-48 99:14-23 @ ./src/comments/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/comments/CommentList.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/comments' @ ./src/comments/CommentList.js 23:0-256 25:64-70 25:112-123 28:37-51 31:36-47 55:4-15 67:6-20 68:20-32 72:44-59 113:6-20 114:20-32 129:44-53 133:48-57 140:38-47 145:79-93 151:38-47 156:38-48 160:39-49 172:68-78 179:62-70 188:6-20 189:97-102 191:39-50 193:46-57 @ ./src/comments/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/comments/PostPreview.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/comments' @ ./src/comments/PostPreview.js 5:0-58 11:42-58 14:46-55 16:39-48 18:39-48 @ ./src/comments/PostReferenceInput.js @ ./src/comments/CommentCreate.js @ ./src/comments/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/comments/PostReferenceInput.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/comments' @ ./src/comments/PostReferenceInput.js 13:0-89 25:20-32 37:13-28 64:91-105 66:39-50 @ ./src/comments/CommentCreate.js @ ./src/comments/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/comments/PostQuickCreate.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/comments' @ ./src/comments/PostQuickCreate.js 15:0-109 27:42-49 29:39-49 61:15-21 78:21-37 84:42-52 95:46-55 97:14-22 98:39-48 100:14-22 @ ./src/comments/PostReferenceInput.js @ ./src/comments/CommentCreate.js @ ./src/comments/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/comments/PostQuickCreateCancelButton.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/comments' @ ./src/comments/PostQuickCreateCancelButton.js 6:0-43 22:20-32 @ ./src/comments/PostQuickCreate.js @ ./src/comments/PostReferenceInput.js @ ./src/comments/CommentCreate.js @ ./src/comments/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/comments/CommentCreate.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/comments' @ ./src/comments/CommentCreate.js 2:0-92 11:64-70 11:112-122 17:12-20 20:37-46 22:12-21 24:37-46 27:37-46 @ ./src/comments/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/posts/ResetViewsButton.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/posts' @ ./src/posts/ResetViewsButton.js 4:0-109 11:17-26 12:22-36 13:18-28 16:7-20 19:12-28 30:42-48 @ ./src/posts/PostList.js @ ./src/posts/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/posts/PostTitle.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/posts' @ ./src/posts/PostTitle.js 2:0-43 7:20-32 @ ./src/posts/PostShow.js @ ./src/posts/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/posts/TagReferenceInput.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/posts' @ ./src/posts/TagReferenceInput.js 6:0-74 38:38-57 42:39-61 @ ./src/posts/PostEdit.js @ ./src/posts/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/posts/PostShow.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/posts' @ ./src/posts/PostShow.js 4:0-284 27:26-43 28:42-50 30:39-55 30:96-99 32:38-47 34:39-48 36:162-171 38:39-49 40:38-46 40:87-96 42:39-47 44:42-45 46:38-51 51:40-43 53:38-57 60:38-53 60:94-103 62:41-50 64:39-50 73:39-50 75:39-51 77:39-48 79:39-50 79:93-96 81:38-56 89:38-46 89:87-96 91:39-48 93:39-48 95:39-49 @ ./src/posts/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/posts/PostList.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/posts' @ ./src/posts/PostList.js 24:0-274 38:20-32 46:61-67 46:109-120 49:37-46 62:33-44 81:196-212 81:255-271 127:42-46 135:49-59 139:40-48 143:38-47 145:39-48 148:39-48 152:39-51 156:39-50 159:39-58 170:38-53 170:94-103 173:103-113 173:155-165 @ ./src/posts/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/posts/PostEdit.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/posts' @ ./src/posts/PostEdit.js 12:0-376 23:42-52 23:93-104 27:50-60 39:42-46 42:46-56 47:38-45 49:38-47 52:39-48 54:14-22 56:39-48 60:14-22 62:39-57 74:39-49 78:38-48 81:67-77 83:38-56 83:97-111 87:38-55 87:98-114 95:87-98 109:42-49 114:14-22 116:40-47 122:39-49 124:38-56 124:97-106 126:39-48 128:41-50 133:39-50 144:39-50 146:15-23 146:27-33 146:37-45 147:39-51 150:39-48 153:40-47 155:38-56 160:38-46 160:87-96 162:39-48 164:39-48 166:39-49 @ ./src/posts/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/posts/PostCreate.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/posts' @ ./src/posts/PostCreate.js 19:0-249 23:68-75 23:117-127 27:37-47 32:37-47 37:37-47 62:42-48 62:90-100 79:38-47 83:38-47 86:40-49 89:39-48 95:14-22 104:59-70 107:39-48 110:39-51 113:39-49 116:15-23 117:38-56 117:97-106 119:39-48 121:68-78 123:38-56 123:97-111 127:38-55 127:98-114 135:87-98 @ ./src/posts/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/tags/TagCreate.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/tags' @ ./src/tags/TagCreate.js 3:0-81 5:60-66 5:108-118 7:36-45 9:37-46 11:13-21 @ ./src/tags/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/tags/TagEdit.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/tags' @ ./src/tags/TagEdit.js 3:0-79 5:58-62 5:104-114 7:36-45 9:37-46 11:13-21 @ ./src/tags/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/tags/TagShow.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/tags' @ ./src/tags/TagShow.js 2:0-64 4:58-62 4:104-120 4:161-170 6:37-46 @ ./src/tags/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/tags/TagList.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/tags' @ ./src/tags/TagList.js 5:0-74 10:58-66 22:6-20 38:87-92 74:103-113 @ ./src/tags/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/users/UserEditEmbedded.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/users' @ ./src/users/UserEditEmbedded.js 13:0-68 25:24-28 27:48-58 31:40-49 34:16-24 @ ./src/users/UserList.js @ ./src/users/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/users/UserShow.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/users' @ ./src/users/UserShow.js 13:0-69 24:42-46 27:46-62 27:103-106 29:38-47 31:39-48 33:67-70 36:38-47 @ ./src/users/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/users/UserTitle.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/users' @ ./src/users/UserTitle.js 3:0-43 9:20-32 @ ./src/users/UserShow.js @ ./src/users/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/users/UserList.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/users' @ ./src/users/UserList.js 15:0-129 26:42-48 26:90-101 29:39-48 31:65-74 36:72-99 48:42-46 61:94-104 64:40-48 68:38-47 70:39-48 72:66-75 @ ./src/users/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/users/UserEdit.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/users' @ ./src/users/UserEdit.js 13:0-173 31:42-49 33:39-49 33:91-114 42:42-52 42:93-104 46:39-49 58:42-46 62:46-56 67:38-45 70:65-74 73:39-48 76:14-22 77:67-74 80:38-49 82:14-22 @ ./src/users/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src

ERROR in ./src/users/UserCreate.js Module not found: Error: Can't resolve 'react-admin' in '/Users/mario/Documents/workspace-experiments/react-admin/examples/simple/src/users' @ ./src/users/UserCreate.js 12:0-119 25:42-49 25:91-101 29:66-76 43:42-48 45:39-49 49:38-45 52:38-47 56:14-22 57:67-74 60:38-55 @ ./src/users/index.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://127.0.0.1:8080 (webpack)/hot/dev-server.js ./src ℹ 「wdm」: Failed to compile.`

Steps to reproduce:

  1. Checkout master branch of react-admin
  2. yarn command in examples/simple
  3. yarn dev command in examples/simple
  4. Running application

Related code:

react-admin simple example

I have similiar issues in my prod project. That was the reason why i tried to compile the simple project.

Environment

fzaninotto commented 3 years ago

What if you run yarn at the root of the react-admin project, instead of in the simple example, as explained in the readme?

The simple example has a custom webpack configuration to ease development within the mono repo, it is not designed to be runnable alone.

msteingruber commented 3 years ago

With the make install and make run-simple command in the root i get the same unmeet dependency warnings but the application works. In my prod application i also get the unmeet dependency warnings and i have to add the final-form dependency manually otherwise my application don't work at all.

The readme of the simple example states:

If you're running this app standalone:

# install dependencies
yarn
# run the app in watch mode (reloads when a change is detected in the app code)
yarn dev

At least the yarn dev only works in the examples/simple folder and not in the root folder

Luwangel commented 3 years ago

I run the simple example using the following commands and it works:

make install run-simple

It allows me to modify the code of react-admin and directly see the changes when I'm developing new features.

If you want to see a standalone usage, you can check the following repo where I cloned the simple example: https://github.com/Luwangel/react-admin-tutorials-build-your-own-theme.

Edit: I edited my message. You have to run make install and not make build.

fzaninotto commented 3 years ago

The simple example readme is wrong, I'm marking this as a documentation bug.