Skip to content

[compiler] Outline jsx with duplicate attributes#31378

Closed
gsathya wants to merge 6 commits into
gh/gsathya/11/basefrom
gh/gsathya/11/head
Closed

[compiler] Outline jsx with duplicate attributes#31378
gsathya wants to merge 6 commits into
gh/gsathya/11/basefrom
gh/gsathya/11/head

Conversation

@gsathya
Copy link
Copy Markdown
Contributor

@gsathya gsathya commented Oct 28, 2024

Stack from ghstack (oldest at bottom):

Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

[ghstack-poisoned]
@vercel
Copy link
Copy Markdown

vercel Bot commented Oct 28, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
react-compiler-playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 6, 2024 5:18pm

gsathya added a commit that referenced this pull request Oct 28, 2024
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

ghstack-source-id: bfcf94b
Pull Request resolved: #31378
@facebook-github-bot facebook-github-bot added CLA Signed React Core Team Opened by a member of the React Core Team labels Oct 28, 2024
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

[ghstack-poisoned]
gsathya added a commit that referenced this pull request Oct 28, 2024
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

ghstack-source-id: bfcf94b
Pull Request resolved: #31378
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

[ghstack-poisoned]
gsathya added a commit that referenced this pull request Oct 28, 2024
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

ghstack-source-id: 32afeab
Pull Request resolved: #31378
Comment thread compiler/packages/babel-plugin-react-compiler/src/Optimization/OutlineJsx.ts Outdated
Comment on lines +9 to +10
<Foo k={i + 'i'}></Foo>
<Foo k={i + 'j'}></Foo>
Copy link
Copy Markdown
Member

@josephsavona josephsavona Oct 30, 2024

Choose a reason for hiding this comment

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

try adding a third child with <Foo k1={i + 'k'}></Foo>

Copy link
Copy Markdown
Member

@josephsavona josephsavona left a comment

Choose a reason for hiding this comment

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

Awesome! Just a couple things to address before landing

Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

[ghstack-poisoned]
gsathya added a commit that referenced this pull request Nov 1, 2024
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

ghstack-source-id: f3a19da
Pull Request resolved: #31378
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

[ghstack-poisoned]
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

[ghstack-poisoned]
gsathya added a commit to gsathya/react that referenced this pull request Nov 6, 2024
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

ghstack-source-id: 3777d99
Pull Request resolved: facebook#31378
gsathya added a commit to gsathya/react that referenced this pull request Nov 6, 2024
Previously, we would skip outlining jsx expressions that had duplicate
jsx attributes as we would not rename them causing incorrect
compilation.

In thir PR, we add outlining support for duplicate jsx attributes by
renaming them.

ghstack-source-id: 3777d99
Pull Request resolved: facebook#31378
@gsathya gsathya closed this Nov 6, 2024
@gsathya gsathya deleted the gh/gsathya/11/head branch November 6, 2024 17:48
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.

3 participants