This project is designed and developed by a team of UC Berkeley students through one of Cal Blueprint's project teams during the 2022-23 academic year.
Learn more about Chinese Newcomers Service Center and Cal Blueprint.
Check your installation of npm
and node
:
node -v
npm -v
This project requires node version 16.17.0.
We strongly recommend using a Node version manager like nvm (for Mac) or nvm-windows (for Windows) to install Node.js and npm. See Downloading and installing Node.js and npm.
- Clone the repo & install dependencies
- Clone this repo
- using SSH (recommended)
git clone [email protected]:calblueprint/chinese-newcomers.git
- using HTTPS
git clone https://github.com/calblueprint/chinese-newcomers.git
- using SSH (recommended)
- Enter the cloned directory
cd chinese-newcomers
- Install Typescript:
npm install -g typescript
- Install yarn:
npm install -g yarn
- Install project dependencies. This command installs all packages from
yarn.lock
.yarn install
- Clone this repo
- Set up secrets:
- In the project's root directory (
chinese-newcomers/
), create a new file named.env
touch .env
- Copy the credentials from Blueprint's internal Notion (access is required) and paste them into the
.env
file.
- In the project's root directory (
Helpful resources
- VSCode (recommended)
- Open the
chinese-newcomers
project in VSCode. - Install recommended workspace VSCode extensions. You should see a pop-up on the bottom right to "install the recommended extensions for this repository".
- Open the
- In the project directory, run:
expo start
- To test the app:
- Expo Go (Recommended): download Expo Go on your phone, connect to same network as your laptop, and use your phone camera to scan the QR code displayed in the command line.
- iOS Simulator: see Expo docs
- Android Emulator: see Expo docs
Starting the expo app results in `FirebaseError: Firebase: Error (auth/invalid-api-key)` but .env exists with the correct credentials.
For whatever reason, sometimes the env variables don't get picked up, but adding the following line to firebaseApp.ts usually fixes it.
console.log(firebaseConfig);