-
-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gazelle extension for TypeScript #2
Comments
I've been trying my hand at this, but it's fraught with speedbumps.
load("@aspect_rules_js//npm:defs.bzl", "npm_package")
load("@aspect_rules_ts//ts:defs.bzl", "ts_config")
load("@npm_dependencies//:defs.bzl", "npm_link_all_packages")
load("//macros/eslint-test:eslint_test.bzl", "eslint_test")
load("//macros/transpile-typescript:transpile_typescript.bzl", "transpile_typescript")
npm_link_all_packages(name = "node_modules")
ts_config(
name = "tsconfig",
src = "tsconfig.json",
)
transpile_typescript(
name = "typescript",
srcs = ["source/render-package-json.ts"],
package_json = "package.json",
tsconfig = ":tsconfig",
deps = [":node_modules/sort-keys"],
)
npm_package(
name = "render-package-json",
srcs = [":typescript"],
visibility = ["//visibility:public"],
)
eslint_test(
name = "eslint_test",
srcs = ["source/render-package-json.ts"],
eslintrc = ".eslintrc.cjs",
package_json = "package.json",
tsconfig = ":tsconfig",
deps = [":node_modules/sort-keys"],
) but it's hacky and nowhere near close enough for a PR. If the trade-offs above are acceptable for now, is there a design document I can conform to while cleaning it up and submit a proof of concept? |
Hi @wtgtybhertgeghgtwtg you made some good progress there! I'm sorry we didn't update this issue sooner - right now we are planning to make the gazelle extension licensed differently from rules_ts so that we have some way to pay our engineers. It does use esbuild's parser, with a little trick to get at the needed API. We have that in a private repo, are you interested in collaborating on it despite that? |
Most of the work I have has been with |
We are close to releasing this feature with the Aspect CLI. Closing this issue as we are developing it closed source in our monorepo. |
Replaces aspect-build/rules_js#20
The text was updated successfully, but these errors were encountered: