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

FED-1855 Update instructions for dart2_upgrade codemod #263

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

greglittlefield-wf
Copy link
Contributor

Motivation

The README referenced a codemod that had been removed, and didn't describe a path forward.

Changes

Update README to show how to run that codemod.

Release Notes

Review

See CONTRIBUTING.md for more details on review types (+1 / QA +1 / +10) and code review process.

Please review:

QA Checklist

  • Tests were updated and provide good coverage of the changeset and other affected code
  • Manual testing was performed if needed

Merge Checklist

While we perform many automated checks before auto-merging, some manual checks are needed:

  • A Frontend Frameworks Design member has reviewed these changes
  • There are no unaddressed comments - this check can be automated if reviewers use the "Request Changes" feature
  • For release PRs - Version metadata in Rosie comment is correct

@greglittlefield-wf greglittlefield-wf changed the title Update instructions for dart2_upgrade codemod FED-1855 Update instructions for dart2_upgrade codemod Nov 3, 2023
@aviary-wf
Copy link

Security Insights

No security relevant content was detected by automated scans.

Action Items

  • Review PR for security impact; comment "security review required" if needed or unsure
  • Verify aviary.yaml coverage of security relevant code

Questions or Comments? Reach out on Slack: #support-infosec.

Copy link
Contributor

@kealjones-wk kealjones-wk left a comment

Choose a reason for hiding this comment

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

Some stuff after the chat continued

README.md Outdated
Comment on lines 33 to 38
over_react component code to be compatible with Dart 2 and the over_react
builder.
The `dart2_upgrade` codemod that used to be provided by this package is no longer available.

Depending on your needs, you may be able to upgrade directly from Dart 1 to
Dart 2, or you may need to take an intermediary step and provide a version of
your codebase that is both forwards- and backwards-compatible. Both of these
options are supported by this codemod.

- `dart pub global run over_react_codemod:dart2_upgrade --backwards-compat`

Use this codemod to migrate your over_react code to a format that is both
forwards-compatible with Dart 2 and backwards-compatible with Dart 1.

- `dart pub global run over_react_codemod:dart2_upgrade`

Use this codemod if you want to migrate to Dart 2 compatible code and do not
need to maintain backwards-compatability with Dart 1. You can run this to
immediately upgrade from Dart 1 to Dart 2, or you can run this on code that
has already been run through this codemod with the `--backwards-compat`
flag once you're ready to drop Dart 1 support.

For more information on the transition from Dart 1 to Dart 2 and how it affects
over_react, check out the [over_react Dart 2 migration guide][over_react_dart2].
It includes sample diffs of the changes that these codemods will introduce.
To use it, activate over_react_codemod 1.12.1 instead of the latest:
```sh
dart pub global activate over_react_codemod ^1.12.1
```
and see its documentation: https://github.com/Workiva/over_react_codemod/tree/1.12.1#dart-1-to-dart-2-codemod
Copy link
Contributor

Choose a reason for hiding this comment

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

After reading the thread with pat is this accurate? or was the final solution to use 1.1.0? also do they need to use a specific dart version? (2.1.0 Was called out in the chat i think?)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Mm good catch, will update

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated; 84685b9

Copy link
Contributor

@kealjones-wk kealjones-wk left a comment

Choose a reason for hiding this comment

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

+10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants