framework7 icon indicating copy to clipboard operation
framework7 copied to clipboard

asyncComponent fails on deep link (live example)

Open fmp777 opened this issue 3 years ago • 0 comments

  • Framework7 version: 7.0.8
  • Svelte version: 3.53.1
  • Platform and Target: Browser
  • CodeSandbox Link: https://codesandbox.io/s/funny-joji-te5yn8?file=/App.svelte

Describe the bug

Using asyncComponent in the route definition results in svelte:component error on deep link.

To Reproduce

  1. Enable browserHistory in the main view
  2. Create a route using asyncComponent => import()
  3. Deep link into the route using asyncComponent
  4. Observe error

In the CodeSandbox

  1. In the app view window, click on ABOUT button.
  2. Note, the browserHistory is enabled.
  3. Now, refresh that view window to simulate a deep link.
  4. Observe the error.

Expected behavior

The page should simply load.

Actual Behavior

Getting a svelte:component JS error.

Screenshots

image

Additional context

Change the route definition to a component instead of asyncComponent and it works fine.

fmp777 avatar Nov 16 '22 17:11 fmp777