-
Notifications
You must be signed in to change notification settings - Fork 12k
ci: add ts api guardian #12010
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
ci: add ts api guardian #12010
Conversation
DId some more fixes for Blocked by:
|
Is this ready to merge? Could you fix conflict? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The benchmark PR was also merged yesterday, and it includes a new package. It probably needs the same kind of codegen that was done in this PR.
Blocked by bazel-contrib/rules_nodejs#316 and bazel-contrib/rules_nodejs#317 |
Requires: angular/angular#26888 |
Been updated and made it work on Windows
angular/angular#26888 is green and marked for merge now |
Marking as need further discussion to decide if we should go for api extractor. |
…tion `ts-api-guardian` only support classic module resolution which means that we need to specify `index` so that the resolution works.
At the moment ts api guardian doesn't support aliased symbols as namespaces, this is a workaround to still have namespaced symbols in the final golden file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The bits that I'm familiar with LGTM.
I still think we should add information about how the API guardian affects the developer story. From the CI config it looks like to test is just bazel test ...
.
Is there anything else that needs to be done as a developer, like updating some of the golden files or something?
@filipesilva you need to update the golden files you if modify the public API. If you touched parts of the API that were aliased, you might need to add these exports in the I can create a readme. Maybe in the contributing section? |
} catch (e) { | ||
if (e && (e.code === 'ENOENT' || e.code === 'ENOTDIR')) { | ||
return false; | ||
export namespace fs { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need a bigger discussion as export namespace ...
is not considered best practices. See https://www.typescriptlang.org/docs/handbook/namespaces-and-modules.html#needless-namespacing
Need discussion as |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving this to get moving.
One of the problems was that in some cases we have the same naming in 2 different "namespaces", and thus this would be that we cannot add it to the If I recall correctly, it was |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
This adds the API guardian in this repo.
Not this doesn't cover
schematics/*
packages. As I'd prefer to tackle that separately as it will require a some more changes and the PR will be way bigger.At the moment, the packages covered are;