svgedit
svgedit copied to clipboard
'noDefaultExtensions' config option is not respected
Describe the bug When 'noDefaultExtensions' config option is set to true - the editor still loads default extensions.
To Reproduce Steps to reproduce the behavior:
- Edit
src/editor/index.html
and changenoDefaultExtensions
parameter to true:
svgEditor.setConfig({
allowInitialUserOverride: true,
extensions: [],
noDefaultExtensions: **true**, // <-- this changed to true
userExtensions: [/* { pathName: './react-extensions/react-test/dist/react-test.js' } */]
});
- npm start
- See that default extensions are still loaded
Expected behavior
If noDefaultExtensions
is set to true
- default extensions must not be loaded. The editor should load only those extensions that are listed in the config extensions
property. E.g. this config:
svgEditor.setConfig({
allowInitialUserOverride: true,
noDefaultExtensions: true,
extensions: [
'ext-panning',
'ext-eyedropper'
]
});
should load 'ext-panning' and 'ext-eyedropper' extensions only.
SVG-Edit environment (IMPORTANT)
- File for SVG-Edit:
index.html
- Version: 7.3.0
- Protocol: http
Desktop (please complete the following information):
- OS: MacOS
- Browser Chrome
- Version 108.0.5359.94