diff --git a/plugins/events-node/alpha-api-report.md b/plugins/events-node/alpha-api-report.md new file mode 100644 index 0000000000..161f80ff87 --- /dev/null +++ b/plugins/events-node/alpha-api-report.md @@ -0,0 +1,36 @@ +## API Report File for "@backstage/plugin-events-node" + +> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). + +```ts +import { ExtensionPoint } from '@backstage/backend-plugin-api'; + +// @alpha (undocumented) +export interface EventsExtensionPoint { + // Warning: (ae-forgotten-export) The symbol "HttpPostIngressOptions" needs to be exported by the entry point alpha.d.ts + // + // (undocumented) + addHttpPostIngress(options: HttpPostIngressOptions): void; + // Warning: (ae-forgotten-export) The symbol "EventPublisher" needs to be exported by the entry point alpha.d.ts + // + // (undocumented) + addPublishers( + ...publishers: Array> + ): void; + // Warning: (ae-forgotten-export) The symbol "EventSubscriber" needs to be exported by the entry point alpha.d.ts + // + // (undocumented) + addSubscribers( + ...subscribers: Array> + ): void; + // Warning: (ae-forgotten-export) The symbol "EventBroker" needs to be exported by the entry point alpha.d.ts + // + // (undocumented) + setEventBroker(eventBroker: EventBroker): void; +} + +// @alpha (undocumented) +export const eventsExtensionPoint: ExtensionPoint; + +// (No @packageDocumentation comment for this package) +``` diff --git a/plugins/events-node/api-report.md b/plugins/events-node/api-report.md index 8428003b85..dfda48d97e 100644 --- a/plugins/events-node/api-report.md +++ b/plugins/events-node/api-report.md @@ -3,8 +3,6 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts -import { ExtensionPoint } from '@backstage/backend-plugin-api'; - // @public export interface EventBroker { publish(params: EventParams): Promise; @@ -40,25 +38,6 @@ export abstract class EventRouter implements EventPublisher, EventSubscriber { abstract supportsEventTopics(): string[]; } -// @alpha (undocumented) -export interface EventsExtensionPoint { - // (undocumented) - addHttpPostIngress(options: HttpPostIngressOptions): void; - // (undocumented) - addPublishers( - ...publishers: Array> - ): void; - // (undocumented) - addSubscribers( - ...subscribers: Array> - ): void; - // (undocumented) - setEventBroker(eventBroker: EventBroker): void; -} - -// @alpha (undocumented) -export const eventsExtensionPoint: ExtensionPoint; - // @public export interface EventSubscriber { onEvent(params: EventParams): Promise; diff --git a/plugins/events-node/package.json b/plugins/events-node/package.json index 9dffabcaac..060e450289 100644 --- a/plugins/events-node/package.json +++ b/plugins/events-node/package.json @@ -6,17 +6,28 @@ "types": "src/index.ts", "license": "Apache-2.0", "publishConfig": { - "access": "public", - "alphaTypes": "dist/index.alpha.d.ts", - "main": "dist/index.cjs.js", - "types": "dist/index.d.ts" + "access": "public" + }, + "exports": { + ".": "./src/index.ts", + "./alpha": "./src/alpha.ts" + }, + "typesVersions": { + "*": { + "*": [ + "src/index.ts" + ], + "alpha": [ + "src/alpha.ts" + ] + } }, "backstage": { "role": "node-library" }, "scripts": { "start": "backstage-cli package start", - "build": "backstage-cli package build --experimental-type-build", + "build": "backstage-cli package build", "lint": "backstage-cli package lint", "test": "backstage-cli package test", "clean": "backstage-cli package clean", @@ -30,7 +41,6 @@ "@backstage/cli": "workspace:^" }, "files": [ - "alpha", "dist" ] } diff --git a/plugins/events-node/src/alpha.ts b/plugins/events-node/src/alpha.ts new file mode 100644 index 0000000000..90666ba2f3 --- /dev/null +++ b/plugins/events-node/src/alpha.ts @@ -0,0 +1,18 @@ +/* + * Copyright 2023 The Backstage Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +export type { EventsExtensionPoint } from './extensions'; +export { eventsExtensionPoint } from './extensions'; diff --git a/plugins/events-node/src/index.ts b/plugins/events-node/src/index.ts index 422eeb169e..2bdf456f13 100644 --- a/plugins/events-node/src/index.ts +++ b/plugins/events-node/src/index.ts @@ -21,5 +21,3 @@ */ export * from './api'; -export type { EventsExtensionPoint } from './extensions'; -export { eventsExtensionPoint } from './extensions';