@@ -17,7 +17,7 @@ function App(props: {faro?: Faro}) {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "/karaktereim",
|
path: "/karaktereim",
|
||||||
element: <CharacterList faro={props.faro} />,
|
element: <CharacterList />,
|
||||||
loader: () => fetch(`api/Character`),
|
loader: () => fetch(`api/Character`),
|
||||||
ErrorBoundary: ErrorBoundary,
|
ErrorBoundary: ErrorBoundary,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
import * as React from "react";
|
import * as React from "react";
|
||||||
import {useLoaderData} from "react-router-dom";
|
import {useLoaderData} from "react-router-dom";
|
||||||
import CharacterListItem, {CharacterListItemDto} from "../components/CharacterListItem";
|
import CharacterListItem, {CharacterListItemDto} from "../components/CharacterListItem";
|
||||||
import {Faro} from "@grafana/faro-web-sdk";
|
|
||||||
|
|
||||||
function CharacterList(props: {faro?: Faro}) {
|
function CharacterList(props: {}) {
|
||||||
const {faro} = props
|
|
||||||
const characters = useLoaderData() as CharacterListItemDto[];
|
const characters = useLoaderData() as CharacterListItemDto[];
|
||||||
|
|
||||||
return <div className="container">
|
return <div className="container">
|
||||||
|
|||||||
Reference in New Issue
Block a user