Closed tk0miya closed 3 months ago
@tk0miya Thanks for your contribution!
Please follow the instructions below for each change. See also: https://github.com/ruby/gem_rbs_collection/blob/main/docs/CONTRIBUTING.md
You can use the following commands by commenting on this PR.
/merge
: Merge this PR if CI passesactionview
You changed RBS files for an existing gem. You need to get approval from the reviewers of this gem.
@ksss, @ydah, please review this pull request.
If this change is acceptable, please make a review comment including APPROVE
from here.
After that, the PR author or the reviewers can merge this PR.
Just comment /merge
to merge this PR.
I would like rbs diff
to have an option to read unified format...
Please wait a moment while I look at the diff.
@tk0miya Is this all the difference you intend?
$ bundle exec rbs diff --detail --format diff --type-name ActionView::Helpers::UrlHelper --before gems/actionview/6.0 --after tk0miya-actionview_urlhelper-patch
- [::ActionView::Helpers::UrlHelper public] def link_to: (?untyped? name, ?untyped? options, ?untyped? html_options) { () -> untyped } -> untyped
+ [::ActionView::Helpers::UrlHelper public] def link_to: (?untyped? name, ?untyped? options, ?untyped? html_options) ?{ () -> untyped } -> untyped
- [::ActionView::Helpers::UrlHelper public] def button_to: (?untyped? name, ?untyped? options, ?untyped? html_options) { () -> untyped } -> untyped
+ [::ActionView::Helpers::UrlHelper public] def button_to: (?untyped? name, ?untyped? options, ?untyped? html_options) ?{ () -> untyped } -> untyped
- [::ActionView::Helpers::UrlHelper public] def link_to_unless_current: (untyped name, ?::Hash[untyped, untyped] options, ?::Hash[untyped, untyped] html_options) { () -> untyped } -> untyped
+ [::ActionView::Helpers::UrlHelper public] def link_to_unless_current: (untyped name, ?::Hash[untyped, untyped] options, ?::Hash[untyped, untyped] html_options) ?{ () -> untyped } -> untyped
- [::ActionView::Helpers::UrlHelper public] def link_to_unless: (untyped condition, untyped name, ?::Hash[untyped, untyped] options, ?::Hash[untyped, untyped] html_options) { () -> untyped } -> untyped
+ [::ActionView::Helpers::UrlHelper public] def link_to_unless: (untyped condition, untyped name, ?::Hash[untyped, untyped] options, ?::Hash[untyped, untyped] html_options) ?{ () -> untyped } -> untyped
- [::ActionView::Helpers::UrlHelper public] def link_to_if: (untyped condition, untyped name, ?::Hash[untyped, untyped] options, ?::Hash[untyped, untyped] html_options) { () -> untyped } -> untyped
+ [::ActionView::Helpers::UrlHelper public] def link_to_if: (untyped condition, untyped name, ?::Hash[untyped, untyped] options, ?::Hash[untyped, untyped] html_options) ?{ () -> untyped } -> untyped
- [::ActionView::Helpers::UrlHelper public] def mail_to: (untyped email_address, ?untyped? name, ?::Hash[untyped, untyped] html_options) { () -> untyped } -> untyped
+ [::ActionView::Helpers::UrlHelper public] def mail_to: (untyped email_address, ?untyped? name, ?::Hash[untyped, untyped] html_options) ?{ () -> untyped } -> untyped
Yes. This commit https://github.com/ruby/gem_rbs_collection/pull/589/commits/6a6c44b1a9342534482d9f35d837e4ae99b970ed is what you want to see.
Now I updated this PR not to move the unrelated methods to actionview.rbs.
Thanks for your review, @ksss!
@tk0miya, @ksss This PR is ready to be merged.
Just comment /merge
to merge this PR.
/merge
These helper methods can be called without block. So it would be better to declare as optional.