Open
Description
What happened?
webhooks
property type of App
cannot be resolved when using Yarn's Plug'n'Play mode.
Here's dist-types/app.d.ts
in [email protected]
:
import { App as DefaultApp } from "@octokit/app";
import { OAuthApp as DefaultOAuthApp } from "@octokit/oauth-app";
export declare const App: (new (...args: any[]) => {
// ...
webhooks: import("@octokit/webhooks").Webhooks<{ // this property resolves its type as `any`.
octokit: import("@octokit/core").Octokit & {
paginate: import("@octokit/plugin-paginate-rest").PaginateInterface;
} & import("@octokit/plugin-paginate-graphql").paginateGraphQLInterface & import("@octokit/plugin-rest-endpoint-methods").Api & {
retry: {
retryRequest: (error: import("@octokit/request-error").RequestError, retries: number, retryAfter: number) => import("@octokit/request-error").RequestError;
};
};
}>;
// ...
}) & typeof DefaultApp;
It's a typical ghost dependency problem; Exported App
type requires dependencies from @octokit/app
to be specified in octokit
's dependencies as well though it's just exporting the types, not actual module.
Here's a workaround for pnp users like me:
packageExtensions:
octokit@*:
dependencies:
"@octokit/webhooks": "*"
Versions
octokit@npm:4.1.3
Code of Conduct
- I agree to follow this project's Code of Conduct
Metadata
Metadata
Assignees
Type
Projects
Status
🆕 Triage