Skip to content

Commit

Permalink
public field definition
Browse files Browse the repository at this point in the history
  • Loading branch information
ilevyor committed Apr 1, 2024
1 parent 4342fef commit 2f8df5a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 19 deletions.
19 changes: 0 additions & 19 deletions crates/core/src/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13030,22 +13030,3 @@ remove_unused_imports()"#
})
.unwrap();
}

#[test]
fn declaration_test() {
run_test_match(TestArg {
pattern: r#"
engine marzano(0.1)
language js
`$event.request.$prop`
"#
.to_owned(),
source: r#"
|const upperLimit = request.request.intent.slots.UpperLimit.value || 100;
|"#
.trim_margin()
.unwrap(),
})
.unwrap();
}
4 changes: 4 additions & 0 deletions crates/language/src/tsx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,10 @@ impl Tsx {
language.id_for_node_kind("import_statement", true),
language.field_id_for_name("type").unwrap(),
),
(
language.id_for_node_kind("public_field_definition", true),
language.field_id_for_name("static").unwrap(),
),
]
});

Expand Down
4 changes: 4 additions & 0 deletions crates/language/src/typescript.rs
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,10 @@ impl TypeScript {
language.id_for_node_kind("import_statement", true),
language.field_id_for_name("type").unwrap(),
),
(
language.id_for_node_kind("public_field_definition", true),
language.field_id_for_name("static").unwrap(),
),
]
});

Expand Down

0 comments on commit 2f8df5a

Please sign in to comment.