Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'noDefaultExtensions' config option is not respected #857

Open
luber opened this issue Dec 4, 2022 · 0 comments
Open

'noDefaultExtensions' config option is not respected #857

luber opened this issue Dec 4, 2022 · 0 comments
Labels

Comments

@luber
Copy link
Contributor

luber commented Dec 4, 2022

Describe the bug
When 'noDefaultExtensions' config option is set to true - the editor still loads default extensions.

To Reproduce
Steps to reproduce the behavior:

  1. Edit src/editor/index.html and change noDefaultExtensions parameter to true:
svgEditor.setConfig({
          allowInitialUserOverride: true,
          extensions: [],
          noDefaultExtensions: **true**, // <-- this changed to true
          userExtensions: [/* { pathName: './react-extensions/react-test/dist/react-test.js' } */]
        });
  1. npm start
  2. 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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants