mirror of
https://github.com/grafana/grafana.git
synced 2026-07-29 15:59:50 -05:00
Import and typescript fixups
This commit is contained in:
@@ -21,8 +21,12 @@ export function reactContainer($route, $location, backendSrv: BackendSrv, dataso
|
||||
restrict: 'E',
|
||||
template: '',
|
||||
link(scope, elem) {
|
||||
let component = $route.current.locals.component.default;
|
||||
let props = {
|
||||
let component = $route.current.locals.component;
|
||||
// Dynamic imports return whole module, need to extract default export
|
||||
if (component.default) {
|
||||
component = component.default;
|
||||
}
|
||||
const props = {
|
||||
backendSrv: backendSrv,
|
||||
datasourceSrv: datasourceSrv,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user