Пакеты
[*] "Expo": "53.0.11"
[*] "Expo-Router": "~ 5.0.7"
[*] "expo-Router": "~ 5.0.7"
[*] "expo-Router": "~ 5.0.7"
[*] " /> "@React-navigation/ящик": "^7.1.1"
[*] "@React-navigation/native": "^7.1.6"
[*] "React": "19.0.0"
react-dom ":" 19.0. /> "React-contive": "0.79.3" < /li>
"react-count-gesture-handler": "~ 2.24.0", < /li>
< /ul>
code < /strong> < /p>
< /ul>
< /strong> < /p>
Код: Выделить всё
import DrawerProfile from "@/components/DrawerProfile";
import { useWindowDimensions } from "react-native";
import { Drawer } from "expo-router/drawer";
export default function MainLayout() {
const { width } = useWindowDimensions();
return (
}
screenOptions={{
headerShown: false,
swipeEnabled: true,
drawerPosition: "left",
drawerType: "back",
overlayColor: "transparent",
drawerStyle: { width, backgroundColor: "transparent" },
}}>
);
}
Нажмите здесь, чтобы увидеть предварительный просмотр
Первоначально отправлено @sumittttpaul в #7565
Подробнее здесь: https://stackoverflow.com/questions/796 ... ter-drawer