-
Notifications
You must be signed in to change notification settings - Fork 112
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
event decorator for components #115
Conversation
I'm considering changing |
I changed
Also currently Storybook show a wrong event definition in This PR fixes this too. I simplified how we document our properties in our component classes by moving description comments to top of every property. Like: /**
* Adds help text
*/
@property({ type: String, attribute: 'help-text' })
helpText?: string;
/**
* Fires when an alteration to the element's value is committed by the user. Unlike the input event, the change event is not necessarily fired for each alteration to an element's value.
*/
@event('bl-change') private onChange: EventDispatcher<string>; @leventozen Please have a look again if this is still good. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job!
Kudos, SonarCloud Quality Gate passed! |
* chore: testing utilities fine tuned * feat: event decorator draft * test: event decorator test coverage increase * fix: linter fixes * feat: event decorator as simple function * refactor: some cleanup * refactor: fix redeclared variable name issue
🎉 This PR is included in version 2.0.0-beta.13 🎉 The release is available on: Your semantic-release bot 📦🚀 |
🎉 This PR is included in version 2.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
@event
decorator implementation.Usage:
With a custom event data type: