diff options
Diffstat (limited to 'CONFIG.md')
| -rw-r--r-- | CONFIG.md | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -104,6 +104,20 @@ https://github.com/angular/vscode-ng-language-service `angular-language-server` can be installed via npm `npm install @angular/language-server`. Be aware there is no global binary and must be run via `node_modules/@angular/language-server/index.js` which can be added as the default cmd. + +Note, that if you override the default `cmd`, you must also update `on_new_config` to set `new_config.cmd` during startup. + +```lua +local project_library_path = "/path/to/project/lib" +local cmd = {"node", "/path/to/node_modules/@angular/language-server/index.js", "--stdio", "--tsProbeLocations", project_library_path , "--ngProbeLocations", project_library_path} + +require'lspconfig'.angularls.setup{ + cmd = cmd, + on_new_config = function(new_config,new_root_dir) + new_config.cmd = cmd + end, +} +``` ```lua |
