Skip to content

Commit 4ff9609

Browse files
authored
fix: import runtime types from @nuxthub/core (#168)
1 parent d0c5b5c commit 4ff9609

File tree

7 files changed

+9
-5
lines changed

7 files changed

+9
-5
lines changed

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@
6262
"@nuxt/module-builder": "^0.7.1",
6363
"@nuxt/schema": "^3.12.1",
6464
"@nuxt/test-utils": "^3.13.1",
65+
"@nuxthub/core": "link:.",
6566
"@types/node": "^20.14.2",
6667
"changelogen": "^0.5.5",
6768
"eslint": "^9.4.0",

pnpm-lock.yaml

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/runtime/blob/app/composables/useMultipartUpload.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { ofetch, type FetchOptions } from 'ofetch'
33
import { joinURL } from 'ufo'
44
import { readonly, ref, type Ref } from 'vue'
55
import type { SerializeObject } from 'nitropack'
6-
import type { BlobUploadedPart, BlobObject } from '../../../../types/blob'
6+
import type { BlobUploadedPart, BlobObject } from '@nuxthub/core'
77

88
/**
99
* Create a multipart uploader.

src/runtime/blob/app/composables/useUpload.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { createError } from 'h3'
22
import type { FetchOptions } from 'ofetch'
3-
import type { BlobObject } from '../../../../types/blob'
3+
import type { BlobObject } from '@nuxthub/core'
44

55
interface UploadOptions extends FetchOptions {
66
/**

src/runtime/blob/server/utils/blob.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ import { defu } from 'defu'
88
import { randomUUID } from 'uncrypto'
99
import { parse } from 'pathe'
1010
import { joinURL } from 'ufo'
11+
import type { BlobType, FileSizeUnit, BlobUploadedPart, BlobListResult, BlobMultipartUpload, HandleMPUResponse, BlobMultipartOptions, BlobUploadOptions, BlobPutOptions, BlobEnsureOptions, BlobObject, BlobListOptions } from '@nuxthub/core'
1112
import { streamToArrayBuffer } from '../../../utils/stream'
1213
import { requireNuxtHubFeature } from '../../../utils/features'
13-
import type { BlobType, FileSizeUnit, BlobUploadedPart, BlobListResult, BlobMultipartUpload, HandleMPUResponse, BlobMultipartOptions, BlobUploadOptions, BlobPutOptions, BlobEnsureOptions, BlobObject, BlobListOptions } from '../../../../types/blob'
1414
import { useRuntimeConfig } from '#imports'
1515

1616
const _r2_buckets: Record<string, R2Bucket> = {}

src/runtime/database/server/utils/database.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ import { ofetch } from 'ofetch'
22
import { joinURL } from 'ufo'
33
import { createError } from 'h3'
44
import type { H3Error } from 'h3'
5+
import type { D1Database } from '@nuxthub/core'
56
import { requireNuxtHubFeature } from '../../../utils/features'
6-
import type { D1Database } from '../../../../types/database'
77
import { useRuntimeConfig } from '#imports'
88

99
let _db: D1Database

src/runtime/kv/server/utils/kv.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ import httpDriver from 'unstorage/drivers/http'
33
import cloudflareKVBindingDriver from 'unstorage/drivers/cloudflare-kv-binding'
44
import { joinURL } from 'ufo'
55
import { createError } from 'h3'
6+
import type { HubKV } from '@nuxthub/core'
67
import { requireNuxtHubFeature } from '../../../utils/features'
7-
import type { HubKV } from '../../../../types/kv'
88
import { useRuntimeConfig } from '#imports'
99

1010
let _kv: HubKV

0 commit comments

Comments
 (0)