Skip to content

Commit

Permalink
fix: keep config type exported in composable
Browse files Browse the repository at this point in the history
  • Loading branch information
manchenkoff committed May 2, 2024
1 parent 978a87f commit 3862bfb
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type {
SanctumModuleOptions,
SanctumGlobalMiddlewarePageMeta,
} from './types';
} from './runtime/types';

declare module 'nuxt/schema' {
interface PublicRuntimeConfig {
Expand Down
2 changes: 1 addition & 1 deletion src/module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
useLogger,
} from '@nuxt/kit';
import { defu } from 'defu';
import type { SanctumModuleOptions } from './types';
import type { SanctumModuleOptions } from './runtime/types';

type DeepPartial<T> = {
[P in keyof T]?: T[P] extends object ? DeepPartial<T[P]> : T[P];
Expand Down
2 changes: 1 addition & 1 deletion src/runtime/composables/useSanctumConfig.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { useRuntimeConfig } from '#app';
import type { SanctumModuleOptions } from '../../types';
import type { SanctumModuleOptions } from '../types';

export const useSanctumConfig = (): SanctumModuleOptions => {
return useRuntimeConfig().public.sanctum as SanctumModuleOptions;
Expand Down
File renamed without changes.

0 comments on commit 3862bfb

Please sign in to comment.