Skip to content
New issue

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

Feature: Support for loading components by promise #41

Open
duruer opened this issue Dec 16, 2020 · 0 comments
Open

Feature: Support for loading components by promise #41

duruer opened this issue Dec 16, 2020 · 0 comments

Comments

@duruer
Copy link

duruer commented Dec 16, 2020

Hi, if you do like this

<Loadable loader="{import('./Test.svelte')}" delay="{delay}">
  <div slot="success" let:component>
    <svelte:component this="{component}" {...params} />
  </div>
</Loadable>

It won't load the component and will give error like; component.then is not a function
Maybe you can detect is it a promise in loader and if it is, it can await it to load?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant