Reorder dependencies (https://github.com/woocommerce/woocommerce-blocks/pull/2774)
This commit is contained in:
parent
d25d233f27
commit
c65fd05a73
|
@ -1,3 +1,20 @@
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import {
|
||||
createContext,
|
||||
useContext,
|
||||
useState,
|
||||
useReducer,
|
||||
useCallback,
|
||||
useEffect,
|
||||
useRef,
|
||||
useMemo,
|
||||
} from '@wordpress/element';
|
||||
import { getSetting } from '@woocommerce/settings';
|
||||
import { useStoreNotices, useEmitResponse } from '@woocommerce/base-hooks';
|
||||
import { useEditorContext } from '@woocommerce/base-context';
|
||||
|
||||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
|
@ -31,23 +48,6 @@ import {
|
|||
} from './event-emit';
|
||||
import { useValidationContext } from '../validation';
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import {
|
||||
createContext,
|
||||
useContext,
|
||||
useState,
|
||||
useReducer,
|
||||
useCallback,
|
||||
useEffect,
|
||||
useRef,
|
||||
useMemo,
|
||||
} from '@wordpress/element';
|
||||
import { getSetting } from '@woocommerce/settings';
|
||||
import { useStoreNotices, useEmitResponse } from '@woocommerce/base-hooks';
|
||||
import { useEditorContext } from '@woocommerce/base-context';
|
||||
|
||||
/**
|
||||
* @typedef {import('@woocommerce/type-defs/contexts').PaymentMethodDataContext} PaymentMethodDataContext
|
||||
* @typedef {import('@woocommerce/type-defs/contexts').PaymentStatusDispatch} PaymentStatusDispatch
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { getValueForQueryKey, getValueForQueryContext } from '../selectors';
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import deepFreeze from 'deep-freeze';
|
||||
|
||||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { getValueForQueryKey, getValueForQueryContext } from '../selectors';
|
||||
|
||||
const testState = deepFreeze( {
|
||||
contexta: JSON.stringify( {
|
||||
foo: 'bar',
|
||||
|
|
|
@ -1,14 +1,14 @@
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import deepFreeze from 'deep-freeze';
|
||||
|
||||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { receiveRoutes } from '../reducers';
|
||||
import { ACTION_TYPES as types } from '../action-types';
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import deepFreeze from 'deep-freeze';
|
||||
|
||||
describe( 'receiveRoutes', () => {
|
||||
it( 'returns original state when action type is not a match', () => {
|
||||
expect( receiveRoutes( undefined, { type: 'invalid' } ) ).toEqual( {} );
|
||||
|
|
|
@ -1,3 +1,9 @@
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import { Elements, useStripe } from '@stripe/react-stripe-js';
|
||||
import { useState } from '@wordpress/element';
|
||||
|
||||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
|
@ -6,12 +12,6 @@ import { getStripeServerData } from '../stripe-utils';
|
|||
import { useCheckoutSubscriptions } from './use-checkout-subscriptions';
|
||||
import { InlineCard, CardElements } from './elements';
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import { Elements, useStripe } from '@stripe/react-stripe-js';
|
||||
import { useState } from '@wordpress/element';
|
||||
|
||||
/**
|
||||
* @typedef {import('../stripe-utils/type-defs').Stripe} Stripe
|
||||
* @typedef {import('../stripe-utils/type-defs').StripePaymentRequest} StripePaymentRequest
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import { Elements, PaymentRequestButtonElement } from '@stripe/react-stripe-js';
|
||||
|
||||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
|
@ -5,11 +10,6 @@ import { getStripeServerData } from '../stripe-utils';
|
|||
import { useInitialization } from './use-initialization';
|
||||
import { useCheckoutSubscriptions } from './use-checkout-subscriptions';
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import { Elements, PaymentRequestButtonElement } from '@stripe/react-stripe-js';
|
||||
|
||||
/**
|
||||
* @typedef {import('../stripe-utils/type-defs').Stripe} Stripe
|
||||
* @typedef {import('../stripe-utils/type-defs').StripePaymentRequest} StripePaymentRequest
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { normalizeLineItems } from './normalize';
|
||||
import { errorTypes, errorCodes } from './constants';
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import { getSetting } from '@woocommerce/settings';
|
||||
import { __ } from '@wordpress/i18n';
|
||||
|
||||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { normalizeLineItems } from './normalize';
|
||||
import { errorTypes, errorCodes } from './constants';
|
||||
|
||||
/**
|
||||
* @typedef {import('./type-defs').StripeServerData} StripeServerData
|
||||
* @typedef {import('./type-defs').StripePaymentItem} StripePaymentItem
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { getSetting } from './get-setting';
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
import compareVersions from 'compare-versions';
|
||||
|
||||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { getSetting } from './get-setting';
|
||||
|
||||
export * from './default-constants';
|
||||
export { setSetting } from './set-setting';
|
||||
|
||||
|
|
Loading…
Reference in New Issue