mirror of
https://github.com/leptos-rs/leptos
synced 2024-11-10 06:44:17 +00:00
do not error on unbraced
This commit is contained in:
parent
6a4fc96835
commit
ba1ea4c2bb
1 changed files with 0 additions and 9 deletions
|
@ -916,15 +916,6 @@ fn attribute_value(attr: &KeyedAttribute) -> TokenStream {
|
|||
None => quote! { true },
|
||||
Some(value) => match &value.value {
|
||||
KVAttributeValue::Expr(expr) => {
|
||||
// value must be a block or literal
|
||||
if !matches!(expr, Expr::Block(_) | Expr::Lit(_)) {
|
||||
emit_error!(
|
||||
expr.span(),
|
||||
"attribute values must be surrounded by braces or be literals";
|
||||
help = "wrap the expression in braces: {{{}}}", expr.to_token_stream(),
|
||||
)
|
||||
}
|
||||
|
||||
if let Expr::Lit(lit) = expr {
|
||||
if cfg!(feature = "nightly") {
|
||||
if let Lit::Str(str) = &lit.lit {
|
||||
|
|
Loading…
Reference in a new issue