@common-stack/client-core
Advanced tools
Comparing version 0.0.198 to 0.0.199
@@ -46,3 +46,3 @@ import { IFeature, FeatureParams, ClientStateParams } from '../interfaces'; | ||
readonly resolvers: any; | ||
readonly getStateParams: any; | ||
readonly getStateParams: ClientStateParams; | ||
readonly connectionParams: any; | ||
@@ -49,0 +49,0 @@ readonly stylesInserts: any[]; |
@@ -154,3 +154,17 @@ module.exports = | ||
get getStateParams() { | ||
return lodash_1.merge({}, ...this.clientStateParams); | ||
return this.clientStateParams.reduce(function (acc, curr) { | ||
const defs = Array.isArray(curr.typeDefs) ? curr.typeDefs : [curr.typeDefs]; | ||
const schema = defs.map(typeDef => { | ||
if (typeof typeDef === 'string') { | ||
return typeDef; | ||
} | ||
console.warn(`Not supported AST format `, typeDef); | ||
}) | ||
.map(str => str.trim()) | ||
.join('\n'); | ||
const typeDefs = acc.typeDefs ? acc.typeDefs.concat(schema) : schema; | ||
const defaults = lodash_1.merge(acc.defaults, curr.defaults); | ||
const resolvers = lodash_1.merge(acc.resolvers, curr.resolvers); | ||
return { defaults, resolvers, typeDefs }; | ||
}, {}); | ||
} | ||
@@ -157,0 +171,0 @@ get connectionParams() { |
{ | ||
"name": "@common-stack/client-core", | ||
"version": "0.0.198", | ||
"version": "0.0.199", | ||
"description": "Sample core for higher packages to depend on", | ||
@@ -56,3 +56,3 @@ "main": "lib/index.js", | ||
"dependencies": { | ||
"@common-stack/core": "^0.0.198" | ||
"@common-stack/core": "^0.0.199" | ||
}, | ||
@@ -59,0 +59,0 @@ "peerDependencies": { |
Sorry, the diff of this file is not supported yet
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
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
40535
464
+ Added@common-stack/core@0.0.199(transitive)
- Removed@common-stack/core@0.0.198(transitive)
Updated@common-stack/core@^0.0.199