Skip to content

[Bug]: <.flash /> without title crashs app at runtime #1527

@nighthawk

Description

@nighthawk

What happened?

If your .swiftui.neex file has this snippet below, it'll crash the app at runtime due to a missing title:

<.flash kind={:info} flash={@flash} />

title is optional according to core_components.swiftui.ex (which is also consistent with the same default component from core_components.ex):

attr :title, :string, default: nil

The crash is in AttributeReference.resolve which has try! even though an error is raised in this case.

Image

Library Version

0.4.0-rc.0

Xcode Version

Version 16.2 (16C5032a)

Swift Version

swift-driver version: 1.115.1 Apple Swift version 6.0.3 (swiftlang-6.0.3.1.10 clang-1600.0.30.1)

On which device or simulator are you running into the problem?

iPad

Target Device Operating System Version

iOS 18.3

Relevant log output

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions