typescript version and import type
This commit is contained in:
3
.vscode/settings.json
vendored
3
.vscode/settings.json
vendored
@@ -2,5 +2,6 @@
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode",
|
||||
"[vue]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
}
|
||||
},
|
||||
"typescript.tsdk": "node_modules/typescript/lib"
|
||||
}
|
||||
|
||||
@@ -2,11 +2,11 @@ import { ACCOUNT_ACCESS } from '~~/prisma/account-access-enum';
|
||||
import prisma_client from '~~/prisma/prisma.client';
|
||||
import {
|
||||
accountWithMembers,
|
||||
AccountWithMembers,
|
||||
type AccountWithMembers,
|
||||
membershipWithAccount,
|
||||
MembershipWithAccount,
|
||||
type MembershipWithAccount,
|
||||
membershipWithUser,
|
||||
MembershipWithUser
|
||||
type MembershipWithUser
|
||||
} from './service.types';
|
||||
import generator from 'generate-password-ts';
|
||||
import { UtilService } from './util.service';
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { ACCOUNT_ACCESS } from '~~/prisma/account-access-enum';
|
||||
import prisma_client from '~~/prisma/prisma.client';
|
||||
import { fullDBUser, FullDBUser } from './service.types';
|
||||
import { fullDBUser, type FullDBUser } from './service.types';
|
||||
import { UtilService } from './util.service';
|
||||
import generator from 'generate-password-ts';
|
||||
|
||||
|
||||
@@ -2,8 +2,8 @@ import { defineEventHandler, parseCookies, setCookie, getCookie } from 'h3';
|
||||
import { serverSupabaseUser } from '#supabase/server';
|
||||
import { AuthService } from '~/lib/services/auth.service';
|
||||
|
||||
import { User } from '@supabase/supabase-js';
|
||||
import { FullDBUser } from '~~/lib/services/service.types';
|
||||
import type { User } from '@supabase/supabase-js';
|
||||
import type { FullDBUser } from '~~/lib/services/service.types';
|
||||
|
||||
// Explicitly type our context by 'Merging' our custom types with the H3EventContext (https://stackoverflow.com/a/76349232/95242)
|
||||
declare module 'h3' {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { ACCOUNT_ACCESS } from '~~/prisma/account-access-enum';
|
||||
import Stripe from 'stripe';
|
||||
import { AccountService } from '~~/lib/services/account.service';
|
||||
import { AccountWithMembers } from '~~/lib/services/service.types';
|
||||
import type { AccountWithMembers } from '~~/lib/services/service.types';
|
||||
|
||||
const config = useRuntimeConfig();
|
||||
const stripe = new Stripe(config.stripeSecretKey, { apiVersion: '2022-11-15' });
|
||||
|
||||
@@ -9,7 +9,7 @@ import {
|
||||
import { ACCOUNT_ACCESS } from '~~/prisma/account-access-enum';
|
||||
import { z } from 'zod';
|
||||
import { AccountService } from '~~/lib/services/account.service';
|
||||
import { MembershipWithAccount } from '~~/lib/services/service.types';
|
||||
import type { MembershipWithAccount } from '~~/lib/services/service.types';
|
||||
|
||||
/*
|
||||
Note on proliferation of Bang syntax... adminProcedure throws if either the ctx.dbUser or the ctx.activeAccountId is not available but the compiler can't figure that out so bang quiesces the null warning
|
||||
|
||||
Reference in New Issue
Block a user