source: pages/star-wars/index/+Page.tsx@ 8ee4553

main
Last change on this file since 8ee4553 was 8ee4553, checked in by Bati <no-reply@…>, 7 months ago

scaffold Vike app with Bati

  • Property mode set to 100644
File size: 541 bytes
RevLine 
[8ee4553]1import { useData } from "vike-react/useData";
2import type { Data } from "./+data.js";
3
4export default function Page() {
5 const { movies } = useData<Data>();
6 return (
7 <>
8 <h1>Star Wars Movies</h1>
9 <ol>
10 {movies.map(({ id, title, release_date }) => (
11 <li key={id}>
12 <a href={`/star-wars/${id}`}>{title}</a> ({release_date})
13 </li>
14 ))}
15 </ol>
16 <p>
17 Source: <a href="https://brillout.github.io/star-wars">brillout.github.io/star-wars</a>.
18 </p>
19 </>
20 );
21}
Note: See TracBrowser for help on using the repository browser.