Skip to content

Commit

Permalink
chore(homescreen): add version number
Browse files Browse the repository at this point in the history
  • Loading branch information
caxewsh committed Sep 17, 2024
1 parent 8f4891b commit 778b0f0
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 0 deletions.
13 changes: 13 additions & 0 deletions components/reusable/VersionNumber.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import React from "react";
import { View, Text } from "react-native";
import * as Application from "expo-application";

const VersionNumber = () => {
return (
<View className="absolute bottom-0 right-0 m-6">
<Text className=" text-gray-500 text-xs font-bold">v{Application.nativeApplicationVersion}</Text>
</View>
);
};

export default VersionNumber;
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
"@supabase/supabase-js": "^2.45.3",
"eas-cli": "^7.3.0",
"expo": "^51.0.32",
"expo-application": "~5.9.1",
"expo-asset": "~10.0.10",
"expo-dev-client": "~4.0.26",
"expo-status-bar": "~1.12.1",
Expand Down
2 changes: 2 additions & 0 deletions screens/Homescreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { useImage } from "../provider/ImageContext";
import Header from "../components/homescreen/Header";
import GifViewer from "../components/homescreen/GifViewer";
import StartButton from "../components/homescreen/StartButton";
import VersionNumber from "../components/reusable/VersionNumber";


export default function HomeScreen() {
Expand All @@ -30,6 +31,7 @@ export default function HomeScreen() {
<Header />
<GifViewer />
<StartButton onPress={goToLobby} />
<VersionNumber />
</SafeAreaView>
</View>
);
Expand Down
5 changes: 5 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5046,6 +5046,11 @@ execa@^5.0.0, execa@^5.1.1:
signal-exit "^3.0.3"
strip-final-newline "^2.0.0"

expo-application@~5.9.1:
version "5.9.1"
resolved "https://registry.yarnpkg.com/expo-application/-/expo-application-5.9.1.tgz#a12e0cf2741b6f084cc49cd0121ad0a70c770459"
integrity sha512-uAfLBNZNahnDZLRU41ZFmNSKtetHUT9Ua557/q189ua0AWV7pQjoVAx49E4953feuvqc9swtU3ScZ/hN1XO/FQ==

expo-asset@~10.0.10:
version "10.0.10"
resolved "https://registry.yarnpkg.com/expo-asset/-/expo-asset-10.0.10.tgz#9e6e02c1a6ec3d19b50d5e615e4dd8e5cc30e857"
Expand Down

0 comments on commit 778b0f0

Please sign in to comment.