зеркало из https://github.com/microsoft/satcheljs.git
fix module cycle
This commit is contained in:
Родитель
2eed2e87bf
Коммит
381fd128d3
|
@ -0,0 +1,7 @@
|
|||
let actionStack: string[] = [];
|
||||
|
||||
export function getCurrentAction() {
|
||||
return actionStack.length ? actionStack[actionStack.length - 1] : null;
|
||||
}
|
||||
|
||||
export default actionStack;
|
|
@ -1,5 +1,5 @@
|
|||
import { action } from 'satcheljs';
|
||||
import { getCurrentAction } from './promiseMiddleware';
|
||||
import { getCurrentAction } from './actionStack';
|
||||
|
||||
export function wrapThen(originalThen: any) {
|
||||
return function wrappedThen(onFulfilled?: Function, onRejected?: Function) {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import { DispatchFunction, ActionFunction, ActionContext } from 'satcheljs';
|
||||
import install from './install';
|
||||
import actionStack from './actionStack';
|
||||
|
||||
let actionStack: string[] = [];
|
||||
let isInstalled = false;
|
||||
let uninstall: () => void;
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче