Skip to content

Conversation

@r0landd
Copy link

@r0landd r0landd commented Jan 12, 2026

Problem

On Windows, setting main = 'nvim-treesitter.configs' causes lazy.nvim to attempt
require('nvim-treesitter.configs'), but this module does not exist in
nvim-treesitter. As a result, Neovim fails to load the plugin.

Other platforms may not trigger the same error, but the configuration
is invalid and can cause issues.

Solution

Remove the main field and rely on lazy.nvim’s default behavior, which
correctly calls require('nvim-treesitter.configs').setup(opts).

Result

Neovim starts normally on Windows (and other platforms) and treesitter
is configured as expected.

@r0landd r0landd force-pushed the fix-treesitter-main branch from abf97a5 to 0ec1900 Compare January 12, 2026 11:49
@r0landd
Copy link
Author

r0landd commented Jan 12, 2026

Removing main avoids the error, but the config still needs a proper setup() call. I’ll reopen with a corrected config.

@r0landd r0landd closed this Jan 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant