mirror of
https://github.com/ArthurDanjou/trpc-nuxt.git
synced 2026-01-26 09:50:31 +01:00
feat: allow changing of src dir
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
import { fileURLToPath } from 'url'
|
||||
import { join, resolve } from 'pathe'
|
||||
import { defu } from 'defu'
|
||||
// @ts-expect-error: No types
|
||||
import dedent from 'dedent'
|
||||
|
||||
import { addPlugin, addServerHandler, addTemplate, defineNuxtModule } from '@nuxt/kit'
|
||||
|
||||
@@ -53,7 +55,7 @@ export default defineNuxtModule<ModuleOptions>({
|
||||
filename: 'trpc-handler.ts',
|
||||
write: true,
|
||||
getContents() {
|
||||
return `
|
||||
return dedent`
|
||||
import { createTRPCHandler } from 'trpc-nuxt/api'
|
||||
import * as functions from '${trpcOptionsPath}'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user