@modern-js-reduck/plugin-auto-actions
Advanced tools
Comparing version 1.1.1 to 1.1.2-alpha.0
@@ -1,3 +0,2 @@ | ||
import { createPlugin } from '@modern-js-reduck/store'; | ||
import { getStateType } from '@modern-js-reduck/store/utils'; | ||
import { createPlugin, utils } from '@modern-js-reduck/store'; | ||
import { mergeActions } from "./utils"; | ||
@@ -10,3 +9,3 @@ import * as primitiveActions from "./primitive"; | ||
const initialState = modelDesc.state; | ||
const type = getStateType(initialState); | ||
const type = utils.getStateType(initialState); | ||
@@ -13,0 +12,0 @@ if (type === 'primitive') { |
@@ -10,6 +10,4 @@ "use strict"; | ||
var _utils = require("@modern-js-reduck/store/utils"); | ||
var _utils = require("./utils"); | ||
var _utils2 = require("./utils"); | ||
var primitiveActions = _interopRequireWildcard(require("./primitive")); | ||
@@ -28,14 +26,15 @@ | ||
const initialState = modelDesc.state; | ||
const type = (0, _utils.getStateType)(initialState); | ||
const type = _store.utils.getStateType(initialState); | ||
if (type === 'primitive') { | ||
return (0, _utils2.mergeActions)(modelDesc, primitiveActions); | ||
return (0, _utils.mergeActions)(modelDesc, primitiveActions); | ||
} | ||
if (type === 'array') { | ||
return (0, _utils2.mergeActions)(modelDesc, arrayActions); | ||
return (0, _utils.mergeActions)(modelDesc, arrayActions); | ||
} | ||
if (type === 'object') { | ||
return (0, _utils2.mergeActions)(modelDesc, (0, _object.createObjectActions)(modelDesc.state)); | ||
return (0, _utils.mergeActions)(modelDesc, (0, _object.createObjectActions)(modelDesc.state)); | ||
} | ||
@@ -42,0 +41,0 @@ |
@@ -1,3 +0,2 @@ | ||
import { createPlugin } from '@modern-js-reduck/store'; | ||
import { getStateType } from '@modern-js-reduck/store/utils'; | ||
import { createPlugin, utils } from '@modern-js-reduck/store'; | ||
import { mergeActions } from "./utils"; | ||
@@ -10,3 +9,3 @@ import * as primitiveActions from "./primitive"; | ||
const initialState = modelDesc.state; | ||
const type = getStateType(initialState); | ||
const type = utils.getStateType(initialState); | ||
@@ -13,0 +12,0 @@ if (type === 'primitive') { |
{ | ||
"name": "@modern-js-reduck/plugin-auto-actions", | ||
"version": "1.1.1", | ||
"version": "1.1.2-alpha.0", | ||
"files": [ | ||
@@ -37,3 +37,3 @@ "dist" | ||
"devDependencies": { | ||
"@modern-js-reduck/store": "1.1.1", | ||
"@modern-js-reduck/store": "1.1.2-alpha.0", | ||
"@modern-js/module-tools": "^1.7.1", | ||
@@ -40,0 +40,0 @@ "@modern-js/plugin-testing": "^1.6.0", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
26609
609
1