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

Minimum changes to support React 16 #78

Conversation

paularmstrong
Copy link
Contributor

Problem: #76 makes too many changes, does much more than just supports React 16.

Solution: Apply only the minimum changeset to allow react-globalize to work with React 15.6.x and 16.x.x

Outstanding issues: The build system looks like it will actually need to be changed, but separately, because esperanto chokes on babel-plugin-transform-class-properties.

@jsf-clabot
Copy link

CLA assistant check
Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Paul Armstrong seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.

@paularmstrong paularmstrong force-pushed the parmstrong/fork-react-16 branch from 5e9b7d1 to e5d9ac8 Compare October 5, 2017 20:23
@paularmstrong paularmstrong mentioned this pull request Oct 5, 2017
@diligiant
Copy link

@paularmstrong aren’t the tests 16.x only? (different enzyme adapter)

@paularmstrong
Copy link
Contributor Author

paularmstrong commented Oct 5, 2017

@diligiant Yes, but I don't see the necessity of creating separate enzyme adapters for 15.6 and 16.x and running the test suite twice, unless there's some sort of regression found. We're using this on Twitter Lite successfully on 15.6 right now.

@diligiant
Copy link

Then shouldn’t this be R16.x only ? How can “it” claim to be compatible with 15.6 if it is not able to test itself with this version ? you and I know it works because we’ve done the manual changes to be sure but that’s irrelevant to people out there who can’t reproduce easily what we’ve done.

On another topic, what do you have in mind to move forward ? Another PR for Rollup and another one for what’s left ? (I’m new here so I ask ;)

Copy link
Contributor

@necolas necolas left a comment

Choose a reason for hiding this comment

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

LGTM. Let's get this merged

.gitignore Outdated
@@ -1,2 +1,3 @@
node_modules/
dist/
.DS_Store
Copy link
Contributor

Choose a reason for hiding this comment

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

Remove? People should have this globally ignored

displayName: Fn,
componentWillMount: function() {
return class extends React.Component {
// static displayName = Fn;
Copy link
Contributor

Choose a reason for hiding this comment

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

Uncomment?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is the Outstanding issues from the description. Esperanto chokes when this is hit, even with the babel plugin.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah, I see

Copy link
Member

Choose a reason for hiding this comment

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

Does that mean we need the tool improvements too?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

They will be needed if you want to support displayName. But that's really only for debugging purposes, so it's not a blocker for things to work.

@rxaviers
Copy link
Member

rxaviers commented Oct 5, 2017

Waiting for @paularmstrong's response on #78 (comment)

@paularmstrong paularmstrong force-pushed the parmstrong/fork-react-16 branch from e5d9ac8 to 9b7b950 Compare October 5, 2017 21:06
@rxaviers
Copy link
Member

rxaviers commented Oct 5, 2017

to work with React 15.6.x and 16.x.x

How should we test 15.x? I believe this is related to #77

@paularmstrong
Copy link
Contributor Author

Apparently grunt/esperanto doesn't actually run babel across the files? That explains the static issue noted inline. Also fails for us building production builds, because the class isn't compiled JS.

The build system needs to be overhauled first. ¯_(ツ)_/¯

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.

5 participants