mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
14 lines
442 B
JavaScript
14 lines
442 B
JavaScript
![]() |
import React from 'react';
|
||
|
import ReactDOM from 'react-dom';
|
||
|
|
||
|
// TODO: Probably need to rehydrate on view restores
|
||
|
|
||
|
export default (view, params, { detail }) => {
|
||
|
if (detail.options?.pageComponent) {
|
||
|
import(/* webpackChunkName: "[request]" */ `./pages/${detail.options.pageComponent}`)
|
||
|
.then(({ default: component }) => {
|
||
|
ReactDOM.render(React.createElement(component), view);
|
||
|
});
|
||
|
}
|
||
|
};
|