File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ import { useTheme } from '@emotion/react';
1111import { useParams } from 'react-router-dom' ;
1212import { useMemeDetailQuery } from '@meme_wiki/apis' ;
1313import { useEffect } from 'react' ;
14- import { COMMAND_TYPE } from '@/types/bridge' ;
14+ import { BridgeCommand , COMMAND_TYPE , CommandType } from '@/types/bridge' ;
1515
1616const MemeDetailPage = ( ) => {
1717 const { memeId } = useParams ( ) ;
@@ -20,8 +20,8 @@ const MemeDetailPage = () => {
2020 const theme = useTheme ( ) ;
2121
2222 useEffect ( ( ) => {
23- window . onNativeEntered = ( type : string ) => {
24- if ( type === COMMAND_TYPE . APP_ENTERED ) {
23+ window . onNativeEntered = ( command : BridgeCommand < CommandType > ) => {
24+ if ( command . type === COMMAND_TYPE . APP_ENTERED ) {
2525 alert ( '앱 접속!' ) ;
2626 } else {
2727 alert ( '웹 접속!' ) ;
Original file line number Diff line number Diff line change @@ -41,6 +41,6 @@ declare global {
4141 } ;
4242 } ;
4343 } ;
44- onNativeEntered ?: ( type : string ) => void ;
44+ onNativeEntered ?: ( command : BridgeCommand < CommandType > ) => void ;
4545 }
4646}
You can’t perform that action at this time.
0 commit comments