What are the Slack Archives?
It’s a history of our time together in the Slack Community! There’s a ton of knowledge in here, so feel free to search through the archives for a possible answer to your question.
Because this space is not active, you won’t be able to create a new post or comment here. If you have a question or want to start a discussion about something, head over to our categories and pick one to post in! You can always refer back to a post from Slack Archives if needed; just copy the link to use it as a reference..
Hey, does anyone have an example extended ZED Config for the webpack build? We're running into the i
Comments
-
backend/build.json
const oryx = require('@spryker/oryx'); const oryxForZed = require('@spryker/oryx-for-zed'); const { join } = require('path'); const customContext = process.cwd(); const projectPath = '/src/'; // deprecated copyAssetsCallback for backward compatibility only const copyAssetsCallback = require('@spryker/oryx-for-zed/lib/copy'); const myCustomZedSettings = Object.assign({}, oryxForZed.settings, { ...oryxForZed.settings, entry: { ...oryxForZed.settings.entry, dirs: [...oryxForZed.settings.entry.dirs, join(customContext, projectPath)], }, }); oryxForZed .getConfiguration(myCustomZedSettings) .then((configuration) => oryx.build(configuration, copyAssetsCallback)) .catch((error) => console.error('An error occurred while creating configuration', error));
0 -
then in package.json just point to your custom build.json
i.e."zed": "node ./backend/build",
0 -
or do u mean something else?
0 -
I'm just asking since we're getting errors from commons.js in regards to missing dependencies/modules
0 -
For example:
ERROR in ./vendor/spryker/gui/assets/Zed/js/modules/commons.js Module not found: Error: Can't resolve 'sweetalert' in '/data/vendor/spryker/gui/assets/Zed/js/modules' @ ./vendor/spryker/gui/assets/Zed/js/modules/commons.js 65:0-21 @ ./vendor/spryker/gui/assets/Zed/js/spryker-zed-gui-commons.entry.js
0 -
@UL65CH0MC did you encounter this issue by any chance as well?
0 -
i don't remember... did u run project install dependencies and zed project install dependencies command before?
vendor/bin/console frontend:project:install-dependencies vendor/bin/console frontend:zed:install-dependencies
0 -
Yes, all dependencies are installed and the error is only showing up when using a modified build for zed
0 -
With default build there are no issues
0 -
can u show me your frontend-build-config.json?
0 -
Initially our plan was to extend the zed config as shown in the article inside the documentation - https://docs.spryker.com/docs/scos/dev/front-end-development/zed/overriding-webpack-js-scss-for-zed-on-project-level.html
There we get no issues during the build process, but rather get issues with the actual frontend and missing modules from commons.js
0 -
The overriding ist just what i sent u yesterday... but with so few details I can't figure out what/where is the problem...
0
Categories
- All Categories
- 42 Getting Started & Guidelines
- 7 Getting Started in the Community
- 8 Additional Resources
- 7 Community Ideas and Feedback
- 76 Spryker News
- 929 Developer Corner
- 787 Spryker Development
- 89 Spryker Dev Environment
- 362 Spryker Releases
- 3 Oryx frontend framework
- 35 Propel ORM
- 68 Community Projects
- 3 Community Ideation Board
- 30 Hackathon
- 3 PHP Bridge
- 6 Gacela Project
- 26 Job Opportunities
- 3.2K 📜 Slack Archives
- 116 Academy
- 5 Business Users
- 370 Docker
- 551 Slack General
- 2K Help
- 75 Knowledge Sharing
- 6 Random Stuff
- 4 Code Testing
- 32 Product & Business Questions
- 70 Spryker Safari Questions
- 50 Random