How to use the neovim.Function function in neovim

To help you get started, we’ve selected a few neovim examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github neoclide / coc.nvim / lib / index.js View on Github external
neovim_1.Function('CocResult', { sync: false })
], CompletePlugin.prototype, "cocResult", null);
tslib_1.__decorate([
    neovim_1.Function('CocCheckHealth', { sync: true })
], CompletePlugin.prototype, "cocCheckHealth", null);
tslib_1.__decorate([
    neovim_1.Function('CocSourceStat', { sync: true })
], CompletePlugin.prototype, "cocSourceStat", null);
tslib_1.__decorate([
    neovim_1.Function('CocSourceToggle', { sync: true })
], CompletePlugin.prototype, "cocSourceToggle", null);
tslib_1.__decorate([
    neovim_1.Function('CocSourceRefresh', { sync: true })
], CompletePlugin.prototype, "cocSourceRefresh", null);
tslib_1.__decorate([
    neovim_1.Function('CocFileTypeChange', { sync: false })
], CompletePlugin.prototype, "cocFileTypeChange", null);
tslib_1.__decorate([
    neovim_1.Function('CocShowSignature', { sync: false })
], CompletePlugin.prototype, "cocShowSignature", null);
tslib_1.__decorate([
    neovim_1.Function('CocShowDefinition', { sync: false })
], CompletePlugin.prototype, "cocShowType", null);
tslib_1.__decorate([
    neovim_1.Command('CocShowDoc', { sync: false, nargs: '*' })
], CompletePlugin.prototype, "cocShowDoc", null);
tslib_1.__decorate([
    neovim_1.Function('CocJumpDefinition', { sync: true })
], CompletePlugin.prototype, "cocJumpDefninition", null);
CompletePlugin = tslib_1.__decorate([
    neovim_1.Plugin({ dev: false })
], CompletePlugin);
github neoclide / coc.nvim / lib / index.js View on Github external
neovim_1.Function('CocInitAsync', { sync: false })
], CompletePlugin.prototype, "cocInitAsync", null);
tslib_1.__decorate([
    neovim_1.Function('CocInitSync', { sync: true })
], CompletePlugin.prototype, "cocInitSync", null);
tslib_1.__decorate([
    neovim_1.Function('CocBufUnload', { sync: false })
], CompletePlugin.prototype, "cocBufUnload", null);
tslib_1.__decorate([
    neovim_1.Function('CocBufChange', { sync: false })
], CompletePlugin.prototype, "cocBufChange", null);
tslib_1.__decorate([
    neovim_1.Function('CocStart', { sync: false })
], CompletePlugin.prototype, "cocStart", null);
tslib_1.__decorate([
    neovim_1.Function('CocInsertCharPre', { sync: true })
], CompletePlugin.prototype, "cocInsertCharPre", null);
tslib_1.__decorate([
    neovim_1.Function('CocInsertLeave', { sync: false })
], CompletePlugin.prototype, "cocInsertLeave", null);
tslib_1.__decorate([
    neovim_1.Function('CocCompleteDone', { sync: true })
], CompletePlugin.prototype, "cocCompleteDone", null);
tslib_1.__decorate([
    neovim_1.Function('CocTextChangedP', { sync: true })
], CompletePlugin.prototype, "cocTextChangedP", null);
tslib_1.__decorate([
    neovim_1.Function('CocTextChangedI', { sync: true })
], CompletePlugin.prototype, "cocTextChangedI", null);
tslib_1.__decorate([
    neovim_1.Function('CocResult', { sync: false })
], CompletePlugin.prototype, "cocResult", null);
github mhartington / nvim-typescript / rplugin / node / nvim_typescript / lib / index.js View on Github external
__metadata("design:returntype", Promise)
], TSHost.prototype, "tssig", null);
__decorate([
    neovim_1.Command('TSRefs'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "tsRefs", null);
__decorate([
    neovim_1.Command('TSEditConfig'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "tsEditconfig", null);
__decorate([
    neovim_1.Function('TSOmnicFunc', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [Object]),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getCompletions", null);
__decorate([
    neovim_1.Function('TSComplete', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [String]),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "tsComplete", null);
__decorate([
    neovim_1.Function('TSDeoplete', { sync: false }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [Array]),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "tsDeoplete", null);
github mhartington / nvim-typescript / rplugin / node / nvim_typescript / lib / index.js View on Github external
__metadata("design:returntype", Promise)
], TSHost.prototype, "getWorkspaceSymbolsFunc", null);
__decorate([
    neovim_1.Function('TSGetProjectInfoFunc', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getProjectInfoFunc", null);
__decorate([
    neovim_1.Command('TSGetDiagnostics'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getDiagnostics", null);
__decorate([
    neovim_1.Function('TSEchoMessage'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "handleCursorMoved", null);
__decorate([
    neovim_1.Command('TSGetCodeFix'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getCodeFix", null);
__decorate([
    neovim_1.Function('TSGetErrorCountForFile', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getErrorsForFile", null);
github mhartington / nvim-typescript / rplugin / node / nvim_typescript / lib / index.js View on Github external
__metadata("design:returntype", Promise)
], TSHost.prototype, "handleCursorMoved", null);
__decorate([
    neovim_1.Command('TSGetCodeFix'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getCodeFix", null);
__decorate([
    neovim_1.Function('TSGetErrorCountForFile', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getErrorsForFile", null);
__decorate([
    neovim_1.Function('TSGetServerPath', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", void 0)
], TSHost.prototype, "tsGetServerPath", null);
__decorate([
    neovim_1.Function('TSGetVersion', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [Object, Object]),
    __metadata("design:returntype", void 0)
], TSHost.prototype, "tsGetVersion", null);
__decorate([
    neovim_1.Function('TSOnBufEnter'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "onBufEnter", null);
github mhartington / nvim-typescript / rplugin / node / nvim_typescript / lib / index.js View on Github external
__metadata("design:returntype", Promise)
], TSHost.prototype, "getErrorsForFile", null);
__decorate([
    neovim_1.Function('TSGetServerPath', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", void 0)
], TSHost.prototype, "tsGetServerPath", null);
__decorate([
    neovim_1.Function('TSGetVersion', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [Object, Object]),
    __metadata("design:returntype", void 0)
], TSHost.prototype, "tsGetVersion", null);
__decorate([
    neovim_1.Function('TSOnBufEnter'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "onBufEnter", null);
__decorate([
    neovim_1.Function('TSOnBufSave'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "onBufSave", null);
__decorate([
    neovim_1.Command('TSStart'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "tsstart", null);
github mhartington / nvim-typescript / rplugin / node / nvim_typescript / lib / index.js View on Github external
__metadata("design:returntype", Promise)
], TSHost.prototype, "getdocsymbols", null);
__decorate([
    neovim_1.Function('TSGetDocSymbolsFunc', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getdocsymbolsFunc", null);
__decorate([
    neovim_1.Command('TSGetWorkspaceSymbols', { nargs: '*' }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [Object]),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getWorkspaceSymbols", null);
__decorate([
    neovim_1.Function('TSGetWorkspaceSymbolsFunc', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [Object]),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getWorkspaceSymbolsFunc", null);
__decorate([
    neovim_1.Function('TSGetProjectInfoFunc', { sync: true }),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getProjectInfoFunc", null);
__decorate([
    neovim_1.Command('TSGetDiagnostics'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "getDiagnostics", null);
github neoclide / coc.nvim / lib / index.js View on Github external
neovim_1.Function('CocStart', { sync: false })
], CompletePlugin.prototype, "cocStart", null);
tslib_1.__decorate([
    neovim_1.Function('CocInsertCharPre', { sync: true })
], CompletePlugin.prototype, "cocInsertCharPre", null);
tslib_1.__decorate([
    neovim_1.Function('CocInsertLeave', { sync: false })
], CompletePlugin.prototype, "cocInsertLeave", null);
tslib_1.__decorate([
    neovim_1.Function('CocCompleteDone', { sync: true })
], CompletePlugin.prototype, "cocCompleteDone", null);
tslib_1.__decorate([
    neovim_1.Function('CocTextChangedP', { sync: true })
], CompletePlugin.prototype, "cocTextChangedP", null);
tslib_1.__decorate([
    neovim_1.Function('CocTextChangedI', { sync: true })
], CompletePlugin.prototype, "cocTextChangedI", null);
tslib_1.__decorate([
    neovim_1.Function('CocResult', { sync: false })
], CompletePlugin.prototype, "cocResult", null);
tslib_1.__decorate([
    neovim_1.Function('CocCheckHealth', { sync: true })
], CompletePlugin.prototype, "cocCheckHealth", null);
tslib_1.__decorate([
    neovim_1.Function('CocSourceStat', { sync: true })
], CompletePlugin.prototype, "cocSourceStat", null);
tslib_1.__decorate([
    neovim_1.Function('CocSourceToggle', { sync: true })
], CompletePlugin.prototype, "cocSourceToggle", null);
tslib_1.__decorate([
    neovim_1.Function('CocSourceRefresh', { sync: true })
], CompletePlugin.prototype, "cocSourceRefresh", null);
github billyvg / tigris.nvim / rplugin / node / tigris.js / src / index.js View on Github external
if (enableFly) {
    parseFunc({ filename, clear: true });

  }
}, DELAY_DEFAULT);

@Plugin({
  name: 'tigris',
})
class TigrisPlugin {
  flyParse(filename) {
    debouncedParser(this.nvim, filename, this.parse.bind(this));
  }

  @Function('tigris_enable')
  async enable() {
    await this.nvim.setVar(ENABLE_VAR, true);
    this.parse();
  }

  @Function('tigris_disable')
  disable() {
    this.nvim.setVar(ENABLE_VAR, false);
    this.clear();
  }

  @Function('tigris_toggle')
  async toggle() {
    const enabled = await this.nvim.getVar(ENABLE_VAR);
    if (enabled) {
      this.disable();
github mhartington / nvim-typescript / rplugin / node / nvim_typescript / lib / index.js View on Github external
__metadata("design:returntype", Promise)
], TSHost.prototype, "tsstart", null);
__decorate([
    neovim_1.Command('TSStop'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "tsstop", null);
__decorate([
    neovim_1.Command('TSReloadProject'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", []),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "reloadProject", null);
__decorate([
    neovim_1.Function('TSCmRefresh'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [Object]),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "onCMRefresh", null);
__decorate([
    neovim_1.Function('TSNcm2OnComplete'),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [Object]),
    __metadata("design:returntype", Promise)
], TSHost.prototype, "onNcm2Complete", null);
TSHost = __decorate([
    neovim_1.Plugin({ dev: true }),
    __metadata("design:paramtypes", [Object])
], TSHost);
exports.default = TSHost;

neovim

Nvim msgpack API client and remote plugin provider

MIT
Latest version published 2 months ago

Package Health Score

81 / 100
Full package analysis