Skip to content

limit_languages doesn't allow for all languages #8

@yochem

Description

@yochem

-- Limit the detection to specific languages.
-- OPTIONAL: If nil, checks against ALL languaages (60+) defined in 'lang_mapping'.
-- This is likely the best way to improve performance.
limit_languages = { "en", "pt_BR" },
})

This doesn't work, because you can't have nil values in Lua tables:

vim.print(vim.tbl_extend('force', { limit_languages = { 'nl' } }, { limit_languages = nil }))

prints the default (lefmost) value. The better option here would be to set limit_languages to an empty array.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions