try
  lua <<EOF
  require'nvim-treesitter.configs'.setup {
    -- Modules and its options go here
    highlight = { enable = true },
    incremental_selection = { enable = true },
    textobjects = { enable = true },
  }
EOF

  set foldmethod=expr
  set foldexpr=nvim_treesitter#foldexpr()
catch
  echo "treesitter is not set up properly"
endtry
