windwp / nvim-ts-autotag

Use treesitter to auto close and auto rename html tag
MIT License
1.61k stars 87 forks source link

Renaming XML tag doesn't work #207

Open julianbopp opened 1 month ago

julianbopp commented 1 month ago

Hello,

renaming tags does not work in XML files:

https://github.com/user-attachments/assets/a0c9e701-3b84-464e-966b-6f5816e562c3

My nvim-ts-autotag config:

require('nvim-ts-autotag').setup {
      opts = {
        -- Defaults
        enable_close = true, -- Auto close tags
        enable_rename = true, -- Auto rename pairs of tags
        enable_close_on_slash = false, -- Auto close on trailing </
      },
      -- Also override individual filetype configs, these take priority.
      -- Empty by default, useful if one of the "opts" global settings
      -- doesn't work well in a specific filetype
      per_filetype = {
        ['xml'] = {
          enable_close = true,
          enable_rename = true, -- Auto rename pairs of tags
        },
      },
      aliases = {
        ['conaryrecipe'] = 'xml',
      },
    }
  end,
PriceHiller commented 1 month ago

Hey @julianbopp can you give this another shot?

Some changes just hit main that may resolve this for you if it has the same root cause as #201.

julianbopp commented 1 month ago

Hey @PriceHiller, thanks for your reply. I updated the plugin and tried again but it still doesn't work :(