Skip to content

Commit d1eea57

Browse files
authored
build: bundle preset types (#3667)
1 parent c8dc542 commit d1eea57

7 files changed

Lines changed: 5 additions & 6 deletions

File tree

build.config.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ export default defineBuildConfig({
9292
"firebase-functions",
9393
"@scalar/api-reference",
9494
"get-port-please", // internal type only
95+
"@cloudflare/workers-types", // issues with rollup-plugin-dts
9596
],
9697
stubOptions: {
9798
jiti: {

src/config/loader.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import consola from "consola";
33
import { resolveCompatibilityDates } from "compatx";
44
import type { CompatibilityDateSpec } from "compatx";
55
import { klona } from "klona/full";
6-
import type { PresetName } from "nitro/presets";
6+
import type { PresetName } from "../presets";
77
import type {
88
LoadConfigOptions,
99
NitroConfig,

src/types/config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import type { LogLevel } from "consola";
1212
import type { ConnectorName } from "db0";
1313
import type { NestedHooks } from "hookable";
1414
import type { ProxyServerOptions } from "httpxy";
15-
import type { PresetName, PresetNameInput, PresetOptions } from "nitro/presets";
15+
import type { PresetName, PresetNameInput, PresetOptions } from "../presets";
1616
import type { TSConfig } from "pkg-types";
1717
import type { Preset as UnenvPreset } from "unenv";
1818
import type { UnimportPluginOptions } from "unimport/unplugin";

src/types/handler.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import type {
55
HTTPEvent,
66
HTTPHandler,
77
} from "h3";
8-
import type { PresetName } from "nitro/presets";
8+
import type { PresetName } from "../presets";
99
import type {
1010
OperationObject,
1111
OpenAPI3,

src/types/nitro.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import type { ConsolaInstance } from "consola";
22
import type { HTTPMethod } from "h3";
33
import type { Hookable } from "hookable";
4-
import type { PresetName, PresetOptions } from "nitro/presets";
4+
import type { PresetName, PresetOptions } from "../presets";
55
import type { Unimport } from "unimport";
66
import type { Storage } from "unstorage";
77
import type { NitroConfig, NitroOptions } from "./config";

test/fixture/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
"nitro/runtime": ["../../src/runtime"],
1414
"nitro/runtime/internal": ["./src/runtime/internal"],
1515
"nitro/runtime/*": ["../../src/runtime/*"],
16-
"nitro/presets": ["../../src/presets"],
1716
"nitro/presets/*": ["../../src/presets/*"],
1817
"nitro/rollup": ["../../src/rollup"],
1918
"nitro/types": ["../../src/types"],

tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@
2424
"nitro": ["./src/index"],
2525
"nitro/runtime": ["./src/runtime"],
2626
"nitro/runtime/internal": ["./src/runtime/internal"],
27-
"nitro/presets": ["./src/presets"],
2827
"nitro/vite": ["./src/vite"],
2928
"nitro/types": ["./src/types"],
3029
"nitro/config": ["./lib/config.mjs"],

0 commit comments

Comments
 (0)