Skip to content

Commit

Permalink
chore(app): initial expo setup (#3)
Browse files Browse the repository at this point in the history
#### What this PR does / why we need it:

Initial barebone expo setup.
  • Loading branch information
fuxingloh committed Jun 19, 2023
1 parent c31b643 commit e99f5b0
Show file tree
Hide file tree
Showing 14 changed files with 7,128 additions and 2 deletions.
17 changes: 15 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,10 @@

# Node
.yarn/*
yarn.lock
.pnp.*
node_modules

package-lock.json
pnpm-lock.yaml

# debug
npm-debug.log*
Expand Down Expand Up @@ -52,3 +51,17 @@ artifacts

# Platforms
.vercel

# Expo
app/.expo/
npm-debug.*
*.jks
*.p8
*.p12
*.key
*.mobileprovision
*.orig.*
web-build/

# Temporary files created by Metro to check the health of the file watcher
.metro-health-check*
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
18.15.0
4 changes: 4 additions & 0 deletions app/AppEntry.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import { registerRootComponent } from 'expo';
import App from './src/App';

registerRootComponent(App);
30 changes: 30 additions & 0 deletions app/app.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"expo": {
"name": "keychain",
"slug": "keychain",
"version": "1.0.0",
"orientation": "portrait",
"icon": "./assets/icon.png",
"userInterfaceStyle": "light",
"splash": {
"image": "./assets/splash.png",
"resizeMode": "contain",
"backgroundColor": "#ffffff"
},
"assetBundlePatterns": [
"**/*"
],
"ios": {
"supportsTablet": true
},
"android": {
"adaptiveIcon": {
"foregroundImage": "./assets/adaptive-icon.png",
"backgroundColor": "#ffffff"
}
},
"web": {
"favicon": "./assets/favicon.png"
}
}
}
Binary file added app/assets/adaptive-icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/favicon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/splash.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions app/babel.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = function(api) {
api.cache(true);
return {
presets: ['babel-preset-expo'],
};
};
23 changes: 23 additions & 0 deletions app/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"name": "@levaintech/keychain-app",
"private": true,
"version": "1.0.0",
"main": "AppEntry.js",
"scripts": {
"start": "expo start",
"android": "expo start --android",
"ios": "expo start --ios",
"web": "expo start --web"
},
"dependencies": {
"expo": "~48.0.18",
"expo-status-bar": "~1.4.4",
"react": "18.2.0",
"react-native": "0.71.8",
"@types/react": "~18.0.27",
"@babel/core": "^7.20.0",
"typescript": "^4.9.4"
},
"devDependencies": {
}
}
20 changes: 20 additions & 0 deletions app/src/App.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import { StatusBar } from 'expo-status-bar';
import { StyleSheet, Text, View } from 'react-native';

export default function App() {
return (
<View style={styles.container}>
<Text>KeyChain — Open up App.js to start working on your app!</Text>
<StatusBar style="auto" />
</View>
);
}

const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#fff',
alignItems: 'center',
justifyContent: 'center',
},
});
4 changes: 4 additions & 0 deletions app/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "expo/tsconfig.base",
"compilerOptions": {}
}
13 changes: 13 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"name": "@levaintech/keychain",
"workspaces": [
"packages/*",
"app"
],
"private": true,
"packageManager": "yarn@1.22.19",
"engines": {
"node": "^18.15.0",
"yarn": "^1.22.19"
}
}

0 comments on commit e99f5b0

Please sign in to comment.