chore: Use types from the web package
This commit is contained in:
@@ -1,23 +1,17 @@
|
||||
import { useQuery } from '@apollo/client';
|
||||
import { AppConfig } from '@automatisch/types';
|
||||
import { AppConfig } from 'types';
|
||||
|
||||
import { GET_APP_CONFIG } from 'graphql/queries/get-app-config.ee';
|
||||
|
||||
type QueryResponse = {
|
||||
getAppConfig: AppConfig;
|
||||
}
|
||||
};
|
||||
|
||||
export default function useAppConfig(key: string) {
|
||||
const {
|
||||
data,
|
||||
loading
|
||||
} = useQuery<QueryResponse>(
|
||||
GET_APP_CONFIG,
|
||||
{
|
||||
variables: { key },
|
||||
context: { autoSnackbar: false }
|
||||
}
|
||||
);
|
||||
const { data, loading } = useQuery<QueryResponse>(GET_APP_CONFIG, {
|
||||
variables: { key },
|
||||
context: { autoSnackbar: false },
|
||||
});
|
||||
const appConfig = data?.getAppConfig;
|
||||
|
||||
return {
|
||||
|
Reference in New Issue
Block a user