When using preact-async-route@2.0.0 my async route renders <undefined></undefined> on the page.
The chunk loads correctly in the network panel but fails to render correctly. If I switch to normal imports the route renders as expected.
import Router from 'preact-router';
import { createHashHistory } from 'history';
import AsyncRoute from 'preact-async-route';
import Home from './Home';
const About = () => import(/* webpackChunkName: "About" */ './About.js').then(module => module.default);
export default class Routes extends React.Component {
constructor(props) {
super(props);
}
render() {
return (
<Router history={createHashHistory()}>
<StylePicker path="/" />
<AsyncRoute path="/home" component={About}/>
</Router>
);
}
}
Reverting to preact-async-route@1.0.3 fixes the issue. Was there a major change that is missing from the docs? Github has the latest release as 1.0.3 but npm has 2.0.0.
When using
preact-async-route@2.0.0
my async route renders<undefined></undefined>
on the page.The chunk loads correctly in the network panel but fails to render correctly. If I switch to normal imports the route renders as expected.
Reverting to
preact-async-route@1.0.3
fixes the issue. Was there a major change that is missing from the docs? Github has the latest release as1.0.3
but npm has2.0.0
.