onivim / oni

Oni: Modern Modal Editing - powered by Neovim
https://www.onivim.io
MIT License
11.35k stars 301 forks source link

Vue / ES6 closing brackets #2496

Open iwasingh opened 6 years ago

iwasingh commented 6 years ago

Oni Version: 0.3.6 Neovim Version (Linux only): 0.3.1 Operating System: Debian 9

Issue: Auto-closing functions brackets does not work. I'm using vue languange server, in particular i'm using Vue 2. Whenever i create a new method/function and type {, oni does not create the closing function bracket }. Everything else is working perfectly.

Expected behavior: A closing bracket } Actual behavior: A closing bracket is missing } Steps to reproduce: type

export default {
 methods: {
     myFunc () {
----> } is missing
--> } is missing
}

This is my config.js

module.exports = {
  "language.vue.languageServer.command": "vls",
  "language.vue.autoClosingPairs.enabled": true,
  "oni.useDefaultConfig": false,
  "oni.loadInitVim": true
}

This is my init.vim

set number
set ignorecase
set smartcase
set expandtab
set shiftwidth=2
set softtabstop=2

Thanks in advance

oni-bot[bot] commented 6 years ago

Hello and welcome to the Oni repository! Thanks for opening your first issue here. To help us out, please make sure to include as much detail as possible - including screenshots and logs, if possible.

CrossR commented 6 years ago

Sorry for the late reply!

I'm not able to reproduce this, could you give some additional information about what keyboard layout you are using, in case that is causing any issues with the auto complete functionality.

As a temporary measure, you can also use any of the existing auto parentheses plugins, until we hopefully fix these awkward cases.

iwasingh commented 6 years ago

Sorry for the late reply!

No problem!

I'm using Italian layout if it helps. I didn't see others having the same issue so, maybe is my configuration problem.
As you suggest, a plugin will definitely work.

Thanks for your time