fix: header link on packages with entrypoints (#11285)

* fix: header link on packages with entrypoints

* types: add types

---------

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
This commit is contained in:
Almeida
2025-11-20 21:22:36 +00:00
committed by GitHub
parent 5130d6f56c
commit 456a6f4548
3 changed files with 13 additions and 4 deletions

View File

@@ -3,7 +3,7 @@ import { join } from 'node:path';
import { PACKAGES_WITH_ENTRY_POINTS } from './constants';
import { ENV } from './env';
export async function fetchEntryPoints(packageName: string, version: string) {
export async function fetchEntryPoints(packageName: string, version: string): Promise<EntryPoint[] | null> {
const hasEntryPoint = PACKAGES_WITH_ENTRY_POINTS.includes(packageName);
if (!hasEntryPoint) {
@@ -37,3 +37,7 @@ export async function fetchEntryPoints(packageName: string, version: string) {
return fileContent.json();
}
export interface EntryPoint {
readonly entryPoint: string;
}