bad JSX and TSX html tag when using 'vat' and 'vit'. #2123
-
Contributing guidelines
Module(s)mini.ai QuestionI was editing a TSX file so I wanted to use the incredible mini.ai text objects but when I tired selecting html tags and custom components it couldn't handle it. then I used :InspectTree from treesitter and I saw a pretty good tag integration but I want to keep using mini.ai and having the good tag integration like one in the treesitter. when I want to select the <motion.h1> tag it selects the outter div insted of the <motion.h1> and it is realy frustrating for me so if anyone can help I will be very tankfull. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
|
Tag textobject in 'mini.ai' is implemented via Lua patterns, which can result in false positives. This particular case is due to the fact that built-in |
Beta Was this translation helpful? Give feedback.
Tag textobject in 'mini.ai' is implemented via Lua patterns, which can result in false positives.
This particular case is due to the fact that built-in
ttextobject only considers tags that contain only alphanumeric characters as their name. Themotion.h1contains.. The #2057 proposed to include the dot by default, but my suggestion is to invest into setting upttextobject that uses tree-sitter parser for a more robust experience.