Closed
Description
For all stumble over this issue update your sulu to the latest supported version (currently: 2.4.9
and 2.5.5
.
All which can not update checkout: #6917 (comment)
Q | A |
---|---|
Sulu Version | 2.5.5 |
PHP Version | 8.1.9 |
DB Version | Ver 8.0.30-0ubuntu0.20.04.2 for Linux on x86_64 ((Ubuntu)) |
Browser Version | FF |
npm | 6.14.17 |
node | v16.17.0 (also tried, v10..) |
Actual Behavior
cd assets/admin
npm run build
...
ERROR in ./node_modules/sulu-admin-bundle/views/Tabs/Tabs.js 105:95
Module parse failed: Unexpected token (105:95)
File was processed with these loaders:
* ./node_modules/babel-loader/lib/index.js
You may need an additional loader to handle the result of these loaders.
| const childComponent = children ? children(childrenProps) : null;
| const selectedTabIndex = selectedIndex !== undefined ? selectedIndex : childComponent ? this.sortedTabRoutes.findIndex(childRoute => childRoute === childComponent.props.route) : undefined;
> const disableGap = selectedTabIndex !== undefined ? this.sortedTabRoutes[selectedTabIndex]?.options?.disableTabGap : false;
| const showTabs = isRootView || this.sortedTabRoutes.length > 1;
| const type = isRootView ? 'root' : 'nested';
.. and so on.
Same with bin/console sulu:admin:update-build
Another issue appears with a similar problem:
ERROR in ./node_modules/htmlparser2/lib/esm/index.js 59:9
Module parse failed: Unexpected token (59:9)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| return getFeed(parseDOM(feed, options));
| }
> export * as DomUtils from "domutils";
| // Old name for DomHandler
| export { DomHandler as DefaultHandler };
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sulu-skeleton@ build: `webpack --mode production`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the sulu-skeleton@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/laravel/.npm/_logs/2022-12-14T11_30_46_625Z-debug.log
Expected Behavior
Builds the admin interface
Steps to Reproduce
bin/console sulu:admin:update-build
Possible Solutions
Tried to downgrade @babel/core and other packages, no success