We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
First off, great work! I love the simplicity of this project.
getLoadableState() should return a promise.
getLoadableState()
getLoadableState() returns an instance of DeferredState if no queries are found.
DeferredState
yarn add loadable-components
node_modules/loadable-components/server/index.js
getLoadableState contains the following line: if (!queries.length) return new _DeferredState2.default([]);
getLoadableState
if (!queries.length) return new _DeferredState2.default([]);
If I download the repo and run yarn build, this is output instead: if (!queries.length) return Promise.resolve(new _DeferredState2.default([]));
yarn build
if (!queries.length) return Promise.resolve(new _DeferredState2.default([]));
Opening up the tarball listed on npm shows the line that isn't wrapped in Promise.resolve, so I think all that needs to be done is to update that.
The text was updated successfully, but these errors were encountered:
Thanks! I will fix it soon.
Sorry, something went wrong.
It was already fixed, I published a new version: https://github.com/smooth-code/loadable-components/releases/tag/v0.2.1
No branches or pull requests
First off, great work! I love the simplicity of this project.
Expected behavior
getLoadableState()
should return a promise.Actual behavior
getLoadableState()
returns an instance ofDeferredState
if no queries are found.Steps to reproduce
yarn add loadable-components
.node_modules/loadable-components/server/index.js
.getLoadableState
contains the following line:if (!queries.length) return new _DeferredState2.default([]);
If I download the repo and run
yarn build
, this is output instead:if (!queries.length) return Promise.resolve(new _DeferredState2.default([]));
Opening up the tarball listed on npm shows the line that isn't wrapped in Promise.resolve, so I think all that needs to be done is to update that.
The text was updated successfully, but these errors were encountered: