klesun / deep-assoc-completion-vscode

A work-in-progress extension for vscode similar to deep-assoc-completion for phpstorm
MIT License
14 stars 0 forks source link

Extension throws error if the project contains "tsconfig.json" in the root project folder #9

Open bogdanbeniaminb opened 2 years ago

bogdanbeniaminb commented 2 years ago

Thank you for this extension! It would fill a great need in PHP when using VS Code.

I have an error on projects that have "tsconfig.json" in the root of the project:


.vscode/extensions/klesun.deep-assoc-completion-vscode-0.9.0/node_modules/deep-assoc-lang-server/src/server.ts:1
import { createConnection, ProposedFeatures, TextDocumentSyncKind, RequestType, } from 'vscode-languageserver';
^^^^^^

SyntaxError: Cannot use import statement outside a module
    at Object.compileFunction (node:vm:352:18)
    at wrapSafe (node:internal/modules/cjs/loader:1085:15)
    at Module._compile (node:internal/modules/cjs/loader:1119:27)
    at Module.m._compile (/home/barbu/.vscode/extensions/klesun.deep-assoc-completion-vscode-0.9.0/node_modules/ts-node/dist/index.js:791:29)
    at Module._extensions..js (node:internal/modules/cjs/loader:1216:10)
    at Object.require.extensions.<computed> [as .ts] (/home/barbu/.vscode/extensions/klesun.deep-assoc-completion-vscode-0.9.0/node_modules/ts-node/dist/index.js:793:16)
    at Module.load (node:internal/modules/cjs/loader:1035:32)
    at Module._load (node:internal/modules/cjs/loader:876:12)
    at Function.c._load (node:electron/js2c/asar_bundle:5:13331)
    at Module.require (node:internal/modules/cjs/loader:1059:19)
[Info  - 10:31:08 AM] Connection to server got closed. Server will restart.
keithbrink commented 2 years ago

Same issue here.