Skip to content

Commit 294a269

Browse files
committed
fix: ensure server composables are type-hinted
1 parent b5c5503 commit 294a269

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/module.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,6 +272,17 @@ export default defineNuxtModule<SanityModuleOptions>({
272272
})
273273

274274
nuxt.hook('nitro:config', (config) => {
275+
config.typescript = defu(config.typescript, {
276+
tsConfig: {
277+
compilerOptions: {
278+
paths: {
279+
['#sanity-client']: [clientPath],
280+
['#sanity-composables']: [composablesFile],
281+
},
282+
},
283+
},
284+
})
285+
275286
if (config.imports === false) return
276287

277288
config.virtual ||= {}

0 commit comments

Comments
 (0)