Skip to content

Rename internal fields#17798

Closed
sebmarkbage wants to merge 1 commit into
react:masterfrom
sebmarkbage:renameinstancehandle
Closed

Rename internal fields#17798
sebmarkbage wants to merge 1 commit into
react:masterfrom
sebmarkbage:renameinstancehandle

Conversation

@sebmarkbage

@sebmarkbage sebmarkbage commented Jan 7, 2020

Copy link
Copy Markdown
Contributor

One day we'll use private fields for this but until then I'm just going to rename these every version until people get the hint.

This is actually better than if we change fields while keeping the same name. Because at least this will fail early (and often bailout) where as once found, people tend to assume that the data structure is there and as such throws random errors to users.

One day we'll use private fields for this but until then I'm just going to
rename these every version until people get the hint.
@codesandbox-ci

codesandbox-ci Bot commented Jan 7, 2020

Copy link
Copy Markdown

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit e381e58:

Sandbox Source
vibrant-sunset-sdlo6 Configuration

@sizebot

sizebot commented Jan 7, 2020

Copy link
Copy Markdown

No significant bundle size changes to report.

Size changes (experimental)

Generated by 🚫 dangerJS against e381e58

@sizebot

sizebot commented Jan 7, 2020

Copy link
Copy Markdown

No significant bundle size changes to report.

Size changes (stable)

Generated by 🚫 dangerJS against e381e58

@gaearon

gaearon commented Jan 7, 2020

Copy link
Copy Markdown
Collaborator

I'm just going to rename these every version

Like.. manually?..

Comment thread packages/react-dom/src/client/ReactDOMComponentTree.js

@gaearon gaearon left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

OK but maybe fix the RN inspector overlay somehow?

@facebook-github-bot facebook-github-bot added the React Core Team Opened by a member of the React Core Team label Jan 8, 2020

@gaearon gaearon left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Let's have a strategy for the cases we found first.

@gaearon gaearon left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Let's get this into the next sync? And fix up the known cases (E2E). We'll need to give heads-up to Enzyme.

@gaearon gaearon mentioned this pull request Mar 24, 2020
@gaearon

gaearon commented Apr 1, 2020

Copy link
Copy Markdown
Collaborator

We did this.

@gaearon gaearon closed this Apr 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed React Core Team Opened by a member of the React Core Team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants