Open
Conversation
p8
reviewed
May 8, 2024
Collaborator
p8
left a comment
There was a problem hiding this comment.
This is looking good. I'm halfway reviewing and hope to continue on friday.
Ridhwana
reviewed
May 9, 2024
Collaborator
There was a problem hiding this comment.
This is looking so good @bhumi1102. I've reviewed until line 300, will send the reviews in batches as I work through the whole file.
p8
reviewed
May 22, 2024
guides/source/form_helpers.md
Outdated
| -------------------------------------------------------------------------------- | ||
|
|
||
| NOTE: This guide is not intended to be a complete documentation of available form helpers and their arguments. Please visit [the Rails API documentation](https://api.rubyonrails.org/classes/ActionView/Helpers.html) for a complete reference of all available helpers. | ||
| NOTE: This guide is not intended to be a complete list of all available form helpers. Please reference [the Rails API documentation](https://api.rubyonrails.org/classes/ActionView/Helpers.html) for an exhaustive list of form helpers and their arguments. |
Collaborator
There was a problem hiding this comment.
Also maybe replace exhaustive with the simpler complete?
Suggested change
| NOTE: This guide is not intended to be a complete list of all available form helpers. Please reference [the Rails API documentation](https://api.rubyonrails.org/classes/ActionView/Helpers.html) for an exhaustive list of form helpers and their arguments. | |
| NOTE: This guide is not intended to be a complete list of all available form helpers. Please reference [the Rails API documentation](https://api.rubyonrails.org/classes/ActionView/Helpers.html) for a complete list of form helpers and their arguments. |
Co-authored-by: Amanda Perino <58528404+AmandaPerino@users.noreply.github.com> Co-authored-by: Petrik de Heus <petrik@deheus.net>
…s into bhumi-guides-form-helpers
Co-authored-by: Karl Lingiah <karl@superchilled.co.uk> Co-authored-by: Petrik de Heus <petrik@deheus.net>
Co-authored-by: Petrik de Heus <petrik@deheus.net>
bhumi1102
pushed a commit
that referenced
this pull request
Dec 11, 2025
* Active storage immediate variants (#6) * This commit introduces variant generation strategies for Active Storage, providing more flexible control over when variants are created. - **:lazily** - variants created dynamically when requested (default) - **:later** - variants created in background after attachment - **:immediately** - variants created simultaneously with attachment ```ruby has_one_attached :avatar_with_lazy_variants do |attachable| attachable.variant :lazy_thumb, resize_to_limit: [3, 3], process: :lazy attachable.variant :default_thumb, resize_to_limit: [4, 4] end has_one_attached :avatar_with_later_variants do |attachable| attachable.variant :later_thumb, resize_to_limit: [2, 2], process: :later end has_one_attached :avatar_with_immediate_variants do |attachable| attachable.variant :immediate_thumb, resize_to_limit: [1, 1], process: :immediately end ``` * Active Storage: make Variant#processed? and VariantWithRecord#processed? public Apps can now check whether variants have been generated. Useful for precise control of variant usage or generation. Co-authored-by: Tom Rossi <tomrossi7@users.noreply.github.com> * Deprecate `preprocessed: true` in favor of `process: :later` For removal in Rails 9.0. Co-authored-by: Tom Rossi <tomrossi7@users.noreply.github.com> * Document immediate variants: guide and changelog Co-authored-by: Tom Rossi <tomrossi7@users.noreply.github.com> * Making ActiveStorage::Preview#processed? a public method Removing space * Use consistent naming for transformations parameter (#7) ActiveStorage uses the plural `transformations` for a single hash of transformation options (e.g., `{ resize_to_limit: [100, 100] }`). To differentiate between a single transformation hash and an array of transformation hashes, this commit introduces `transformations_array` for arrays of transformations, while retaining transformations for individual hashes. * Fixing changelog * Rename transformations_array to variants Aligns with `CreateVariantsJob` naming and `ActiveStorage` terminology where variants represent the result of transformations applied to the original blob. Fixing create_preview_image --------- Co-authored-by: Jeremy Daer <jeremy@rubyonrails.org> Co-authored-by: Tom Rossi <tomrossi7@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This one is ready for internal review. It is a bit long but not too bad.
Among other edits and code example updates, I've address the bullet points from the Todo:
--> agree, removed.
_form_with model: @article_ is 100% correct, might need to double check that.--> yes. updated this example and got the HTML output from my "guides playground" rails app.
record.persisted?in record identification, could be a good plug to link to the Active Model guide on that.--> Hm...there is no direction mention, other than this https://guides.rubyonrails.org/active_model_basics.html#conversion
_**options_being all that it takes, instead of explicitly showing all possible kwargs.--> Yeah, not sure what to do about this one. Was thinking about removing it as there is not built-in support to showcase.