File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11const fs = require ( 'fs' ) ;
22const projectRootPath = __dirname ;
3- const AddonConfigurationRegistry = require ( '@plone/registry/src /addon-registry' ) ;
3+ const { AddonRegistry } = require ( '@plone/registry/addon-registry' ) ;
44
55let coreLocation ;
66if ( fs . existsSync ( `${ projectRootPath } /core` ) )
77 coreLocation = `${ projectRootPath } /core` ;
88else if ( fs . existsSync ( `${ projectRootPath } /../../core` ) )
99 coreLocation = `${ projectRootPath } /../../core` ;
1010
11- const registry = new AddonConfigurationRegistry (
12- `${ coreLocation } /packages/volto` ,
13- ) ;
11+ const { registry } = AddonRegistry . init ( `${ coreLocation } /packages/volto` ) ;
1412
1513// Extends ESlint configuration for adding the aliases to `src` directories in Volto addons
1614const addonAliases = Object . keys ( registry . packages ) . map ( ( o ) => [
Original file line number Diff line number Diff line change @@ -107,9 +107,9 @@ module.exports = {
107107 [ ] ,
108108 defaultRazzleOptions ,
109109 ) ;
110- const AddonConfigurationRegistry = require ( '@plone/registry/src /addon-registry' ) ;
110+ const { AddonRegistry } = require ( '@plone/registry/addon-registry' ) ;
111111
112- const registry = new AddonConfigurationRegistry ( projectRootPath ) ;
112+ const { registry } = AddonRegistry . init ( projectRootPath ) ;
113113
114114 config = lessPlugin ( { registry } ) . modifyWebpackConfig ( {
115115 env : { target : 'web' , dev : 'dev' } ,
You can’t perform that action at this time.
0 commit comments