diff --git a/.civet/hera-plugin.mjs b/.civet/hera-plugin.mjs index b8be3bd4..3f8222a6 100644 --- a/.civet/hera-plugin.mjs +++ b/.civet/hera-plugin.mjs @@ -4,15 +4,14 @@ const { compile: heraCompile } = Hera export default { transpilers: [{ extension: ".hera", - target: ".cjs", + target: ".ts", compile: function (path, source) { - const code = heraCompile(source, { + return heraCompile(source, { filename: path, + sourceMap: true, + types: true, + module: true, }) - - return { - code - } } }], } diff --git a/lsp/package.json b/lsp/package.json index 8e4d4329..2311c683 100644 --- a/lsp/package.json +++ b/lsp/package.json @@ -94,7 +94,7 @@ "dependencies": {}, "devDependencies": { "@danielx/civet": "^0.6.72", - "@danielx/hera": "^0.7.12", + "@danielx/hera": "^0.8.11", "@types/mocha": "^9", "@types/node": "^14.17.0", "@types/vscode": "^1.63.0", diff --git a/lsp/source/extension.civet b/lsp/source/extension.civet index abb47812..bc3131b1 100644 --- a/lsp/source/extension.civet +++ b/lsp/source/extension.civet @@ -45,6 +45,7 @@ function activateClient(context: ExtensionContext) documentSelector: [ { scheme: 'file', language: 'civet' } { scheme: 'file', language: 'coffeescript' } + { scheme: 'file', language: 'hera' } { scheme: 'file', language: 'javascript' } { scheme: 'file', language: 'javascriptreact' } { scheme: 'file', language: 'typescript' } diff --git a/lsp/yarn.lock b/lsp/yarn.lock index 56a91a35..7bfafa4d 100644 --- a/lsp/yarn.lock +++ b/lsp/yarn.lock @@ -277,10 +277,10 @@ "@typescript/vfs" "^1.5.0" unplugin "^1.6.0" -"@danielx/hera@^0.7.12": - version "0.7.12" - resolved "https://registry.yarnpkg.com/@danielx/hera/-/hera-0.7.12.tgz#ce26d3ed052c39d23baf1b65e9c7de6dc38ad80d" - integrity sha512-YPqnLGZH7EML3t7u8KlBwjg9rv5h0gWIt8Kr3sZYB6rq1bqHgv30yQAyBs0hf1WTB76NQgA0ErJeIRbOuzRahw== +"@danielx/hera@^0.8.11": + version "0.8.11" + resolved "https://registry.yarnpkg.com/@danielx/hera/-/hera-0.8.11.tgz#ccf8ba4a231a0b1308bb0ee24b03c1c25d5b3488" + integrity sha512-1AQVUh0uji4ExSZk62vYQ6K152j+CZN1E6i39/Jb3z3A4b3VqYByezHwcg4mZloT4RWaPo35zT5pwtnwutNIcQ== "@esbuild/android-arm64@0.19.2": version "0.19.2"