📜  反应原生使用路由参数 - Javascript代码示例

📅  最后修改于: 2022-03-11 15:02:02.091000             🧑  作者: Mango

代码示例2
import * as React from 'react';
import { Text } from 'react-native';
import { useRoute } from '@react-navigation/native';

function MyText() {
  const route = useRoute();

  return {route.params.caption};
}