3.10 Assets
If your plugin provides JavaScript or CSS, make sure assets follow the new structure compatible with the TestApplication.
1. Create the new structure
assets/
├── admin/
│ ├── entrypoint.js
├── shop/
│ ├── entrypoint.js
2. Handling old asset locations
If your plugin still keeps assets under:
src/Resources/private/
src/Resources/public/
Recommended: move them to the new
assets/admin
orassets/shop
directories and update import paths.Optional: if moving the files is complicated or would break existing references, it is acceptable to keep them in the old location (
public/
) for now. Make sure the paths are still correctly referenced in your tests or application.
3. Change symlink
rm -f node_modules
ln -sf vendor/sylius/test-application/node_modules node_modules
4. Build
Once assets are organized, build them from the TestApplication directory:
yarn install --cwd vendor/sylius/test-application
yarn --cwd vendor/sylius/test-application encore dev
Note: Following the new structure is recommended for consistency and future compatibility, but leaving assets in public/
is allowed if migration is too complex.
Last updated
Was this helpful?