import { useLocalSearchParams } from "expo-router";
import { TownSelectionPage } from "../../../src/screens/town_selection/town_selection_page";

export default function Index() {
  const { stateId } = useLocalSearchParams<{stateId: string}>();
  if (!stateId) {
    throw new Error("stateId is required");
  }
  return (
    <TownSelectionPage stateId={+stateId}/>
  );
}