Visitar URL original
Support parsing Flow's Optional Indexed Access Types by gkz 路 Pull Request #13224 路 babel/babel 路 GitHub
Skip to content

Support parsing Flow's Optional Indexed Access Types - #13224

Merged
nicolo-ribaudo merged 1 commit into
babel:feat-7.14.0/parser-updatesfrom
gkz:flow-optional-indexed-access
Apr 27, 2021
Merged

nicolo-ribaudo merged 1 commit into
babel:feat-7.14.0/parser-updatesfrom
gkz:flow-optional-indexed-access

Conversation

@gkz

@gkz gkz commented Apr 27, 2021 •

Copy link
Copy Markdown
Contributor

This stacked on #13053 (which is not in main, but in branch feat-7.14.0/parser-updates, so I'm targeting that branch).

Optional Indexed Access (e.g. T?.['foo']) is like optional chaining but for indexed access.

This PR also fixes a small issue with IndexedAccessType type definitions, by adding aliases: ["Flow", "FlowType"]

Q 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 A
Fixed Issues?
Patch: Bug Fix?
Major: Breaking Change?
Minor: New Feature? Yes
Tests Added + Pass? Yes
Documentation PR Link
Any Dependency Changes?
License MIT

@babel-bot

babel-bot commented Apr 27, 2021 •

Copy link
Copy Markdown
Collaborator

Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/45632/

@codesandbox-ci

codesandbox-ci Bot commented Apr 27, 2021 •

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 59e4312:

Sandbox Source
babel-repl-custom-plugin Configuration
babel-plugin-multi-config Configuration

Comment thread packages/babel-generator/src/generators/flow.ts Outdated
Comment thread packages/babel-parser/src/plugins/flow/index.js Outdated
@gkz
gkz force-pushed the flow-optional-indexed-access branch from 693092b to bdf2b54 Compare April 27, 2021 02:02
Comment thread packages/babel-parser/src/plugins/flow/index.js Outdated
@gkz
gkz force-pushed the flow-optional-indexed-access branch from bdf2b54 to 59e4312 Compare April 27, 2021 02:15
@nicolo-ribaudo nicolo-ribaudo added the PR: New Feature 馃殌 A type of pull request used for our changelog categories label Apr 27, 2021
@nicolo-ribaudo nicolo-ribaudo added this to the v7.14.0 milestone Apr 27, 2021
@nicolo-ribaudo
nicolo-ribaudo merged commit d6e7535 into babel:feat-7.14.0/parser-updates Apr 27, 2021
@github-actions github-actions Bot added the outdated A closed issue/PR that is archived due to age. Recommended to make a new issue label Jul 28, 2021
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Jul 28, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area: flow outdated A closed issue/PR that is archived due to age. Recommended to make a new issue pkg: parser PR: New Feature 馃殌 A type of pull request used for our changelog categories

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants