Skip to content

BaseButton: removing autobind usage#4279

Merged
dzearing merged 2 commits intomicrosoft:masterfrom
dzearing:button-autobind
Mar 16, 2018
Merged

BaseButton: removing autobind usage#4279
dzearing merged 2 commits intomicrosoft:masterfrom
dzearing:button-autobind

Conversation

@dzearing
Copy link
Copy Markdown
Member

Attempting to remove autobind usage in BaseButton to understand:

  1. does it affect bundle size at all
  2. can we just use this simple pattern and get rid of having to import autobind and have code to do this.

Also, in general, I believe we may want to get away from decorators, so I'm looking at what that might look like here.

@dzearing
Copy link
Copy Markdown
Member Author

dzearing commented Mar 15, 2018

@christiango @cschleiden @antonlabunets I think we will want to do this in bulk and get rid of autobind usage. it is easier, smaller, requires no import, and has no probability of failing because of a bad tslib __decorate update.

You can see that just updating this one file removed almost 100 bytes off the gzip size.

@Markionium
Copy link
Copy Markdown
Member

I like this! :D Can help to do the same thing in other components if thats helpful.

@dzearing dzearing merged commit 25a4bd1 into microsoft:master Mar 16, 2018
@dzearing dzearing deleted the button-autobind branch March 16, 2018 03:31
@dzearing
Copy link
Copy Markdown
Member Author

@Markionium yes please! That would be massively helpful.

@cschleiden
Copy link
Copy Markdown
Contributor

@dzearing I'm still a fan of autobind ;) But sure, I'm fine with the changes.

@Markionium Markionium mentioned this pull request Mar 17, 2018
2 tasks
@microsoft microsoft locked as resolved and limited conversation to collaborators Aug 31, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants