Open ApolloTang opened 3 years ago
Above is my attempt setting the flag:
"buildProjectReferences": true,
But to no avail :(
So what's happening is the "project"
field in typescript.json
resolves relative to the project root, so it's looking for a file under /apps/app--node-1/tsconfig.heft.json
. If you change the "project"
field's value to "node_modules/@myscope/heft-node-rig/profiles/default/config/tsconfig.heft.json"
, you'll get your expected behavior.
I guess this begs the question: what is the expected behavior here? Would a different resolution be more intuitive? @octogonz @dmichon-msft, thoughts on this?
Summary
According to https://github.com/microsoft/rushstack/issues/2258#issuecomment-895595035
However, when a heft project is rigged, in rig's configuration, it is unclear which tscconfig.json the configuration is read from, and the result is in effect that the typescript task being disabled as described in https://github.com/microsoft/rushstack/issues/2258#issuecomment-895595035:
Repro steps
Set up a rigged heft project and specify a custom tsconfig.json in the
project
field. See example repo:https://github.com/ApolloTang/study--rush--node-app/blob/main/02b-node-apps-w-rig--typescript-json-project/tools/heft-node-rig/profiles/default/config/typescript.json#L15
Expected result:
Expect the specified tsconfig.json to be adopted and the typescript task run.
Actual result:
Typescript task is disabled
Details
Detailed discussion in zulip:
https://rushstack.zulipchat.com/#narrow/stream/262522-heft/topic/.E2.9C.94.20.5Brig.5D.20file.20path.20for.20project.20field.20in.20typescript.2Ejson
Standard questions
Please answer these questions to help us investigate your issue more quickly:
@rushstack/heft
version?node -v
)?