Skip to content

탄소저감 크레딧 플랫폼, 탄플 - 클라이언트

License

Notifications You must be signed in to change notification settings

GWjun/tanple-client

 
 

Repository files navigation


tanple icon

탄소저감 크레딧 플랫폼, 탄플 - 클라이언트

React Native badge Expo badge Zustand badge TanStack Query badge React Native Paper badge Lottie badge

페이지 개요

  1. 온보딩

  2. 물품 목록

  3. 물품 인증

  4. 카드 웹뷰

  5. 알림 확인

  6. 크레딧 이용

  7. 배출권 거래

Getting Started

Information

React Native 0.73.6
Expo SDK 50.0.14
Expo Router
Airbnb ESLint & Prettier
React Native Paper

Installation

  1. Clone the repository:
git clone https://github.com/inha-tanple/tanple-client.git
  1. Navigate to the project directory:
cd tanple-client
  1. Install dependencies:
npm install

Usage

  1. Make [.env] file in root directory
# google Ouath 2.0 client ID
ANDROID_CLIENT_ID=
IOS_CLIENT_ID=
EXPO_CLIENT_ID=
WEB_CLIENT_ID=

# your backend server URL
SERVER_URL=
  1. Make [env.d.ts] file in root directory
declare module '@env' {
  export const ANDROID_CLIENT_ID: string
  export const IOS_CLIENT_ID: string
  export const EXPO_CLIENT_ID: string
  export const WEB_CLIENT_ID: string
  export const SERVER_URL: string
}
  1. Make [expo-env.d.ts] file in root directory
/// <reference types="expo/types" />

// NOTE: This file should not be edited and should be in your git ignore
  1. Package Install & Edit file like this
    ./node_modules/react-native-snap-carousel/src/carousel/Carousel.js
    ./node_modules/react-native-snap-carousel/src/Pagination/Pagination.js
    ./node_modules/react-native-snap-carousel/src/Pagination/PaginationDot.js
    ./node_modules/react-native-snap-carousel/src/ParallaxImage/ParallaxImage.js
npm install
// from
import { ... ,ViewPropTypes } from 'react-native';

// to
import { ... } from 'react-native';
import {ViewPropTypes} from 'deprecated-react-native-prop-types';
  1. Put google-services.json on root directory

    You need to register a firebase key for the notification service.
    Follow the instructions at the address below. https://docs.expo.dev/push-notifications/fcm-credentials/

  2. (Optional) You can toggle the Storybook screen by commenting out the below in '/src/app/layout.tsx'.

    [Current react-native-skia version doesn't support storybook]

// other codes ...
export { default } from '../../.storybook'
// other codes ...

Build

You can build it by creating an [eas.json] file and adding env option.

{
  "cli": {
    "version": ">= 7.6.2"
  },
  "build": {
    "preview": {
      "distribution": "internal",
      "env": {
        "ANDROID_CLIENT_ID": "",
        "IOS_CLIENT_ID": "",
        "EXPO_CLIENT_ID": "",
        "WEB_CLIENT_ID": "",
        "SERVER_URL": "",
        "ANDROID_NDK": "/home/expo/Android/Sdk/ndk/25.1.8937393"
      },
      "ios": {
        "simulator": true
      },
      "android": {
        "ndk": "25.1.8937393"
      }
    },
    "production": {}
  },
  "submit": {
    "production": {}
  }
}
# run on ios simulator
npm run ios

# run on android emulator
npm run android

# build android
eas build -p android --profile preview

# build ios
eas build -p ios --profile preview

About

탄소저감 크레딧 플랫폼, 탄플 - 클라이언트

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 97.4%
  • JavaScript 2.6%