Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#1028 (comment) > Actually I may have overthought this. Lucky wants to avoid bugs, but also be practical. Sometimes nils can sneak in when you don't expect it...but maybe label_text is not one of those places. I have a hard time seeing a use case where someone is conditionally generating a label and it might accidentally be nil. I think of all the apps I've ever written I've never accidentally set label text to nil. > So I think what I'll do is make the label text String?. So that if you pass nil to text it will infer the label name like it does now when you leave the arg off completely. That way we can still keep the component flexible by allowing String? but we also keep label_for flexible. I'll go ahead and make that change now. This also means existing apps will still work when you upgrade and this will no longer be a breaking change 👍
- Loading branch information