Skip to content

Support Class Functions as React Props #221

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

omrimn
Copy link

@omrimn omrimn commented May 11, 2025

Overview

This PR enhances the function transform logic to support resolving functions defined as class methods on the custom element's container. Previously, only global or window-scoped functions could be referenced by name.

Now, if a function prop is passed as an attribute and matches a method on the element's container (using camelCase conversion), it will be correctly resolved and bound to the element.

@omrimn omrimn changed the title Support class function to react props Support Class Functions as React Props May 11, 2025
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.

1 participant