Open
Description
Expected Behavior
Storyblok client is possible to initialize with resolveNestedRelations
disabled.
Current Behavior
Initializing the Storyblok client with resolveNestedRelations
flag disabled, does not correctly set the initial value
const Storyblok = new StoryblokClient({
accessToken: '<TOKEN>',
resolveNestedRelations: false,
});
Temporary workaround
Manually set flag AFTER the storyblok client initialization.
Storyblok.resolveNestedRelations = false;
Steps to Reproduce
https://runkit.com/embed/xx23fbgocz7c
Potential defect
When passing resolveNestedRelations: false,
as part of init object, the resolveNestedRelations
should be set to false, but due to this.resolveNestedRelations = config.resolveNestedRelations || true
in the
storyblok-js-client/src/index.ts
Line 150 in d04da2e
We might replace ||
with ??
