-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ASA Mobile: Capacitor Skeleton (#4214)
- Adds a capacitor app using react/vite that renders a basic `FBAMap` with pmtiles layers as well as a header and set of tabs. - Application code is mostly copied from web
- Loading branch information
Showing
54 changed files
with
9,620 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
lerna-debug.log* | ||
|
||
node_modules | ||
dist | ||
dist-ssr | ||
*.local | ||
|
||
# Editor directories and files | ||
.vscode/* | ||
!.vscode/extensions.json | ||
.idea | ||
.DS_Store | ||
*.suo | ||
*.ntvs* | ||
*.njsproj | ||
*.sln | ||
*.sw? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# ASA Go | ||
|
||
Capacitor app using react/vite. | ||
|
||
## Building | ||
|
||
1. `yarn install` | ||
2. `yarn build` | ||
|
||
## Setup live reload | ||
|
||
1. Install ionic CLI and native run for live reload with: `npm install -g @ionic/cli native-run` | ||
|
||
### Building/Running iOS | ||
|
||
1. Make sure xcode is installed with `xcode-select --install` | ||
2. Go to `mobile/asa-go/ios` | ||
3. Install/update cocoapods with `gem install cocoapods` | ||
4. Go to `mobile/asa-go` | ||
5. Run `yarn cap sync` to synchronize app with native platforms | ||
6. Build and run with live reload: `ionic cap run ios -l --external` | ||
|
||
### Building/Running Android | ||
|
||
1. Install Android Studio (Jetbrains Toolbox recommended: https://www.jetbrains.com/toolbox-app/) | ||
2. Find where the Android SDK is installed | ||
- With Jetbrains Toolbox it should be /Users/<user>/Library/Android/sdk/ | ||
- Set `$ANDROID_HOME` to the path of the Android SDK | ||
3. Go to `mobile/asa-go` | ||
4. Run `yarn cap sync` to synchronize app with native platforms | ||
5. Build and run with live reload: `ionic cap run android -l --external` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import type { CapacitorConfig } from '@capacitor/cli'; | ||
|
||
const config: CapacitorConfig = { | ||
appId: 'io.ionic.starter', | ||
appName: 'asa-go', | ||
webDir: 'dist' | ||
}; | ||
|
||
export default config; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
import js from '@eslint/js' | ||
import globals from 'globals' | ||
import reactHooks from 'eslint-plugin-react-hooks' | ||
import reactRefresh from 'eslint-plugin-react-refresh' | ||
import tseslint from 'typescript-eslint' | ||
|
||
export default tseslint.config( | ||
{ ignores: ['dist'] }, | ||
{ | ||
extends: [js.configs.recommended, ...tseslint.configs.recommended], | ||
files: ['**/*.{ts,tsx}'], | ||
languageOptions: { | ||
ecmaVersion: 2020, | ||
globals: globals.browser, | ||
}, | ||
plugins: { | ||
'react-hooks': reactHooks, | ||
'react-refresh': reactRefresh, | ||
}, | ||
rules: { | ||
...reactHooks.configs.recommended.rules, | ||
'react-refresh/only-export-components': [ | ||
'warn', | ||
{ allowConstantExport: true }, | ||
], | ||
}, | ||
}, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link rel="icon" type="image/svg+xml" href="/vite.svg" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover"> | ||
<title>ASA Go</title> | ||
</head> | ||
<body> | ||
<div id="root"></div> | ||
<script type="module" src="/src/main.tsx"></script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"name": "asa-go", | ||
"integrations": { | ||
"capacitor": {} | ||
}, | ||
"type": "react-vite" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
App/build | ||
App/Pods | ||
App/output | ||
App/App/public | ||
DerivedData | ||
xcuserdata | ||
|
||
# Cordova plugins for Capacitor | ||
capacitor-cordova-ios-plugins | ||
|
||
# Generated Config files | ||
App/App/capacitor.config.json | ||
App/App/config.xml |
Oops, something went wrong.