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

♻️ Use includedProperties instead of ignoredProperties #1522

Merged
merged 2 commits into from
Feb 6, 2023

Conversation

aswetlow
Copy link
Member

Proposed Changes

Extending the Jovo class with additional properties caused Maximum call stack size exceeded exceptions in the JovoDebugger if they contained a reference to the jovo object.

This PR proposes to change the approach to includedProperties instead of ignoring these properties via ignoredProperties.

ignoredProperties is still available to prevent a breaking change.

Best practice if you want to extend the includedProperties array

import { DEFAULT_INCLUDED_PROPERTIES, JovoDebugger } from '@jovotech/plugin-debugger';

...
 new JovoDebugger({
    includedProperties: [...DEFAULT_INCLUDED_PROPERTIES, '$foobar'],
  }),
...

Types of Changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • My code follows the code style of this project
  • My change requires a change to the documentation
  • I have updated the documentation accordingly
  • I have added tests to cover my changes
  • All new and existing tests passed

@aswetlow aswetlow requested a review from jankoenig January 26, 2023 14:02
Copy link
Member

@jankoenig jankoenig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! 🎉

@jankoenig jankoenig merged commit 23c5d33 into v4/dev Feb 6, 2023
@jankoenig jankoenig deleted the v4/improvement/jovo-debugger branch February 6, 2023 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants