code-style: eslint fixes
This commit is contained in:
parent
ff6a669c1e
commit
3a52ce3647
@ -4,4 +4,5 @@ node_modules
|
||||
yarn.lock
|
||||
package-lock.json
|
||||
**/*.test.js
|
||||
coverage
|
||||
coverage
|
||||
mocks
|
||||
@ -1,3 +1,4 @@
|
||||
/* eslint-disable import/prefer-default-export */
|
||||
import { createGlobalStyle } from 'styled-components';
|
||||
|
||||
export const GlobalStyle = createGlobalStyle`
|
||||
|
||||
@ -1,3 +1,5 @@
|
||||
/* eslint-disable no-underscore-dangle */
|
||||
/* eslint-disable @typescript-eslint/naming-convention */
|
||||
import { ApolloClient, InMemoryCache } from '@apollo/client';
|
||||
|
||||
/** @type {import('@apollo/client').ApolloClient<NormalizedCacheObject>} */
|
||||
@ -16,7 +18,7 @@ function createApolloClient() {
|
||||
});
|
||||
}
|
||||
|
||||
export function initializeApollo(initialState = null) {
|
||||
export default function initializeApollo(initialState = null) {
|
||||
const _apolloClient = apolloClient ?? createApolloClient();
|
||||
|
||||
// If your page has Next.js data fetching methods that use Apollo Client, the initial state
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
/* eslint-disable import/prefer-default-export */
|
||||
import { useMemo } from 'react';
|
||||
import { initializeApollo } from './client';
|
||||
import initializeApollo from './client';
|
||||
|
||||
export function useApollo(initialState) {
|
||||
const client = useMemo(() => initializeApollo(initialState), [initialState]);
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
import { initializeApollo } from 'apollo/client';
|
||||
import initializeApollo from 'apollo/client';
|
||||
import type { GetServerSideProps } from 'next';
|
||||
import { fetchUser } from 'services/user';
|
||||
import type { BasePageProps } from 'types/page';
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
/* eslint-disable import/prefer-default-export */
|
||||
import axios, { AxiosRequestConfig } from 'axios';
|
||||
import type { User } from './types';
|
||||
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
/* eslint-disable object-curly-newline */
|
||||
/* eslint-disable import/no-cycle */
|
||||
import type { Elements } from 'Components/Calculation/types/elements';
|
||||
import type { Elements } from 'Components/Calculation/config/map';
|
||||
import { makeAutoObservable } from 'mobx';
|
||||
import RootStore from 'stores/root';
|
||||
import type { CalculationStatuses, Status } from './types';
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user