chore: fix/hero-now-slot 병합 — 안 쓰는 네이티브 화면·패키지 정리(mobile 81개 파일, 15개 패키지), 히어로 '지금' 날씨를 지금이 든 3시간 칸으로, 앱 버전 1.1.2(1005). region.tsx 는 main 의 최신(탭 이동 시 위치 되돌아감 수정 + 지역 창 기록 처리)을 그대로 둠
This commit is contained in:
commit
cd77589d86
89 files changed
+70
-9214
No files matched your search
+3
-6
@@ -98,12 +98,9 @@ GA4 태그(`gtag.js`, 측정 ID `G-D378J4X373`)를 `index.html`에 심고, 화
|
||||
|
||||
## 앱 (안드로이드, `mobile/`)
|
||||
|
||||
- **웹뷰 셸 전환(`feat/app-webview-shell`)**: 앱이 날씨각 웹을 웹뷰로 띄우는 껍데기가 되면 아래 앱 이벤트는 쓰지 않고, 웹이 같은 이벤트를 그대로 보내며 `platform: 'android_app'`으로 찍힌다. 앱 안에서 구글 로그인·공유·위치가 실패하면 `app_bridge_error`, 앱을 켜면 `app_launch`(`mode: 'android_app'`)가 나간다. 앱 사용자는 `platform`으로 가른다.
|
||||
|
||||
- 앱도 같은 이벤트 이름·값으로 `track()`을 부른다 (`mobile/src/lib/analytics.ts`). 모든 이벤트에 `platform: 'app'`이 붙는다.
|
||||
- **아직 GA4로 보내지 않는다 (2026-11-04).** Firebase Analytics(`google-services.json`)를 붙이면 앱 시작 때 `setAnalyticsSender`로 보내는 함수를 단다. 그 전까지 `track()`은 아무것도 보내지 않는다. 개발 빌드(`__DEV__`)는 붙인 뒤에도 보내지 않는다.
|
||||
- 앱에서 부르는 곳: `sheet_open`(`components/sheets/index.tsx`), `view_gak`(`sheets/gak.tsx`), `select_content`(`sheets/article.tsx`), `login`·`sign_up`(`sheets/login.tsx`, 구글만), `region_change`(`sheets/region.tsx`·`lib/region.tsx`), `like`(`post/post-card.tsx` 글, `sheets/comments.tsx` 댓글), `comment`·`report`·`block`·`terms_agree`(`sheets/comments.tsx`), `share`(`lib/share-image.ts`), `hero_day_switch`(`today/hero.tsx`), `like`의 `hero_post`·`gak_post`(`lib/pinned-like.ts`). 레벨 창·레벨업 창은 `sheet_open`(`level`·`levelUp`)으로 잡힌다. 동네 이야기: `talk_post`(`components/talk/talk.tsx` `Composer`), `like`·`report`·`block`의 `talk`(`talk/talk.tsx`), `talk_comment`(`sheets/comments.tsx`), `feed_item_view`(`app/(tabs)/index.tsx` `useSeen`, 화면에 반쯤 보일 때). 내 각: `my_gak_save`(`lib/my-gak.ts`), 만들기·상세 창은 `sheet_open`(`mix`·`myGak`). 오늘 아이콘 줄: `today_icon`(`components/today/icons.tsx`). 사주: `saju_input`(`components/saju/birth-form.tsx`), `saju_view`(`saju/reading.tsx`). 단풍 지도: `foliage_open`(`app/foliage.tsx`), `foliage_spot`(`components/foliage/*`, 화면 `page`·피드 카드 `card`). 쇼츠: `shorts_open`·`shorts_view`·`shorts_sound`(`app/shorts/[id].tsx`). 구름 합치기 게임은 앱이 웹 `/game`을 웹뷰로 띄우므로 `game_start`·`game_round`·`game_over`는 웹 페이지가 보내고 `platform: 'web'`으로 찍힌다(앱 안 게임과 웹 게임을 GA에서 나눠 볼 수 없음).
|
||||
- 앱 `share`의 `ratio`는 `'card'` — 보이는 카드를 그대로 찍어 보내 비율을 고르지 않는다.
|
||||
- 앱은 날씨각 웹을 웹뷰로 띄우는 껍데기라(`mobile/src/components/web-shell.tsx`) 앱에서 따로 보내는 이벤트가 없다. 웹이 같은 이벤트를 그대로 보내고 `platform: 'android_app'`으로 찍힌다. 앱 사용자는 `platform`으로 가른다.
|
||||
- 앱에서만 나가는 것: 앱을 켜면 `app_launch`(`mode: 'android_app'`), 앱 안에서 구글 로그인·공유·위치가 실패하면 `app_bridge_error`. 둘 다 웹 코드가 보낸다.
|
||||
- 예전 네이티브 화면과 그 화면의 `track()`(`mobile/src/lib/analytics.ts`)은 지웠다. 새 화면·이벤트는 웹(`frontend/`)에만 더한다.
|
||||
|
||||
## GA4 설정
|
||||
|
||||
|
||||
Reference in new issue
Block a user