Ltex-ls and spelling woes

I am trying to stop ltex-ls from doing spell checking. I have nvim spell. It’s enough for my needs. The grammar is a good thing™ and thus I want to use ltex-ls. I have updated everything to the latest versions via PackerUpdate just incase.

Sadly, I cannot fathom how to configure it so I get:

Here is some background that might be useful:

√ ; /home/usr/.local/share/nvim/lsp_servers/ltex/ltex-ls-15.2.0/bin/ltex-ls --version
{
  "ltex-ls": "15.2.0",
  "java": "11.0.12"
}
√ ; nvim --version
NVIM v0.6.0
Build type: Debug
LuaJIT 2.1.0-beta3

And the configuration I am using:

-- Ltex
nvim_lsp.ltex.setup {
  on_attach = on_attach,
  settings = {
    ltex = {
      disabledRules = { ['en-US'] = { 'PROFANITY', 'MORFOLOGIK_RULE_EN_US' } },
      dictionary = {
        ['en-US'] = {'newwordtoinclude', 'anotherword'},
      },
    },
  },
}

Could a kind soul help me?

Often times it will take awhile for a user to get a response to a question that is somewhat niche to a particular language server, usually bumping your own question is counterproductive. Fortunately discourse has a great search feature, so your topic is still discoverable a long time after posting.

I personally have no idea, I’ve only tested the default settings with ltex. There’s a pool of people who commented on the ltex PR, might reach out to one of those (or file a feature request for managing this in the grammar guard extension)

I have similar settings as you:

      lspconfig.ltex.setup{
        on_attach = on_attach,
        autostart = false,
        settings = {
          ltex = {
            disabledRules = {
              ["en"]    = { "MORFOLOGIK_RULE_EN"    },
              ["en-AU"] = { "MORFOLOGIK_RULE_EN_AU" },
              ["en-CA"] = { "MORFOLOGIK_RULE_EN_CA" },
              ["en-GB"] = { "MORFOLOGIK_RULE_EN_GB" },
              ["en-NZ"] = { "MORFOLOGIK_RULE_EN_NZ" },
              ["en-US"] = { "MORFOLOGIK_RULE_EN_US" },
              ["en-ZA"] = { "MORFOLOGIK_RULE_EN_ZA" },
              ["es"]    = { "MORFOLOGIK_RULE_ES"    },
              ["it"]    = { "MORFOLOGIK_RULE_IT_IT" },
              ["de"]    = { "MORFOLOGIK_RULE_DE_DE" },
            },
          },
        },
      }

And the rules are disabled in my environment. Perhaps, your locale is not en-US, so try disabling all variations of English.