chore: introduce imports ordering (#5463)
This commit is contained in:
committed by
GitHub
parent
30f0e7b031
commit
dbf2920254
@ -1,15 +1,7 @@
|
||||
import { Base64 } from 'js-base64';
|
||||
import type { Semaphore } from 'semaphore';
|
||||
import semaphore from 'semaphore';
|
||||
import { initial, last, partial, result, trimStart, trim } from 'lodash';
|
||||
import { oneLine } from 'common-tags';
|
||||
import type {
|
||||
AssetProxy,
|
||||
DataFile,
|
||||
PersistOptions,
|
||||
FetchError,
|
||||
ApiRequest,
|
||||
} from 'netlify-cms-lib-util';
|
||||
import {
|
||||
getAllResponses,
|
||||
APIError,
|
||||
@ -33,6 +25,15 @@ import {
|
||||
throwOnConflictingBranches,
|
||||
} from 'netlify-cms-lib-util';
|
||||
import { dirname } from 'path';
|
||||
|
||||
import type {
|
||||
AssetProxy,
|
||||
DataFile,
|
||||
PersistOptions,
|
||||
FetchError,
|
||||
ApiRequest,
|
||||
} from 'netlify-cms-lib-util';
|
||||
import type { Semaphore } from 'semaphore';
|
||||
import type { Octokit } from '@octokit/rest';
|
||||
|
||||
type GitHubUser = Octokit.UsersGetAuthenticatedResponse;
|
||||
|
@ -1,6 +1,4 @@
|
||||
import type { QueryOptions, MutationOptions, OperationVariables } from 'apollo-client';
|
||||
import { ApolloClient } from 'apollo-client';
|
||||
import type { NormalizedCacheObject } from 'apollo-cache-inmemory';
|
||||
import {
|
||||
InMemoryCache,
|
||||
defaultDataIdFromObject,
|
||||
@ -18,11 +16,15 @@ import {
|
||||
throwOnConflictingBranches,
|
||||
} from 'netlify-cms-lib-util';
|
||||
import { trim, trimStart } from 'lodash';
|
||||
|
||||
import introspectionQueryResultData from './fragmentTypes';
|
||||
import type { Config, BlobArgs } from './API';
|
||||
import API, { API_NAME, PullRequestState, MOCK_PULL_REQUEST } from './API';
|
||||
import * as queries from './queries';
|
||||
import * as mutations from './mutations';
|
||||
|
||||
import type { Config, BlobArgs } from './API';
|
||||
import type { NormalizedCacheObject } from 'apollo-cache-inmemory';
|
||||
import type { QueryOptions, MutationOptions, OperationVariables } from 'apollo-client';
|
||||
import type { GraphQLError } from 'graphql';
|
||||
import type { Octokit } from '@octokit/rest';
|
||||
|
||||
|
@ -1,4 +1,5 @@
|
||||
import { Base64 } from 'js-base64';
|
||||
|
||||
import API from '../API';
|
||||
|
||||
global.fetch = jest.fn().mockRejectedValue(new Error('should not call fetch inside tests'));
|
||||
|
@ -1,6 +1,7 @@
|
||||
import GitHubImplementation from '../implementation';
|
||||
import { Cursor, CURSOR_COMPATIBILITY_SYMBOL } from 'netlify-cms-lib-util';
|
||||
|
||||
import GitHubImplementation from '../implementation';
|
||||
|
||||
jest.spyOn(console, 'error').mockImplementation(() => {});
|
||||
|
||||
describe('github backend implementation', () => {
|
||||
|
@ -1,21 +1,7 @@
|
||||
import * as React from 'react';
|
||||
import type { Semaphore } from 'semaphore';
|
||||
import semaphore from 'semaphore';
|
||||
import trimStart from 'lodash/trimStart';
|
||||
import { stripIndent } from 'common-tags';
|
||||
import type {
|
||||
AsyncLock,
|
||||
Implementation,
|
||||
AssetProxy,
|
||||
PersistOptions,
|
||||
DisplayURL,
|
||||
User,
|
||||
Credentials,
|
||||
Config,
|
||||
ImplementationFile,
|
||||
UnpublishedEntryMediaFile,
|
||||
Entry,
|
||||
} from 'netlify-cms-lib-util';
|
||||
import {
|
||||
CURSOR_COMPATIBILITY_SYMBOL,
|
||||
Cursor,
|
||||
@ -35,11 +21,27 @@ import {
|
||||
unsentRequest,
|
||||
branchFromContentKey,
|
||||
} from 'netlify-cms-lib-util';
|
||||
|
||||
import AuthenticationPage from './AuthenticationPage';
|
||||
import type { Octokit } from '@octokit/rest';
|
||||
import API, { API_NAME } from './API';
|
||||
import GraphQLAPI from './GraphQLAPI';
|
||||
|
||||
import type { Octokit } from '@octokit/rest';
|
||||
import type {
|
||||
AsyncLock,
|
||||
Implementation,
|
||||
AssetProxy,
|
||||
PersistOptions,
|
||||
DisplayURL,
|
||||
User,
|
||||
Credentials,
|
||||
Config,
|
||||
ImplementationFile,
|
||||
UnpublishedEntryMediaFile,
|
||||
Entry,
|
||||
} from 'netlify-cms-lib-util';
|
||||
import type { Semaphore } from 'semaphore';
|
||||
|
||||
type GitHubUser = Octokit.UsersGetAuthenticatedResponse;
|
||||
|
||||
const MAX_CONCURRENT_DOWNLOADS = 10;
|
||||
|
@ -1,4 +1,5 @@
|
||||
import { gql } from 'graphql-tag';
|
||||
|
||||
import * as fragments from './fragments';
|
||||
|
||||
// updateRef only works for branches at the moment
|
||||
|
@ -1,5 +1,6 @@
|
||||
import { gql } from 'graphql-tag';
|
||||
import { oneLine } from 'common-tags';
|
||||
|
||||
import * as fragments from './fragments';
|
||||
|
||||
export const repoPermission = gql`
|
||||
|
Reference in New Issue
Block a user