Showing
4 changed files
with
22 additions
and
8 deletions
... | @@ -2,8 +2,8 @@ | ... | @@ -2,8 +2,8 @@ |
2 | "devToolsPort": 19002, | 2 | "devToolsPort": 19002, |
3 | "expoServerPort": 19000, | 3 | "expoServerPort": 19000, |
4 | "packagerPort": 19001, | 4 | "packagerPort": 19001, |
5 | - "packagerPid": 30416, | 5 | + "packagerPid": 27784, |
6 | "expoServerNgrokUrl": "https://ru-c66.bluejoy.searchguide.exp.direct", | 6 | "expoServerNgrokUrl": "https://ru-c66.bluejoy.searchguide.exp.direct", |
7 | "packagerNgrokUrl": "https://packager.ru-c66.bluejoy.searchguide.exp.direct", | 7 | "packagerNgrokUrl": "https://packager.ru-c66.bluejoy.searchguide.exp.direct", |
8 | - "ngrokPid": 9812 | 8 | + "ngrokPid": 16708 |
9 | } | 9 | } | ... | ... |
1 | -import React from 'react'; | 1 | +import React, {useEffect, useState} from 'react'; |
2 | import Main from './components/Main/Main' | 2 | import Main from './components/Main/Main' |
3 | import { Provider,connect } from 'react-redux'; | 3 | import { Provider,connect } from 'react-redux'; |
4 | import Store from './reducers/Store'; | 4 | import Store from './reducers/Store'; |
5 | +import * as Font from 'expo-font'; | ||
5 | 6 | ||
6 | const App = () => { | 7 | const App = () => { |
7 | - return ( | 8 | + const [ fontLoaded,setFontLoaded ] = useState(false); |
8 | - <Provider store={Store}> | 9 | + useEffect( () => { |
9 | - <Main /> | 10 | + const fontLoading = async () => { |
10 | - </Provider> | 11 | + await Font.loadAsync({ |
11 | - ) | 12 | + 'CustomFont': require('./assets/font/NanumBarunGothic.ttf'), |
13 | + 'CustomFontBold': require('./assets/font/NanumBarunGothicBold.ttf') | ||
14 | + }); | ||
15 | + setFontLoaded(true); | ||
16 | + } | ||
17 | + fontLoading(); | ||
18 | + }, [] ) | ||
19 | + return ( | ||
20 | + <Provider store={Store}> | ||
21 | + { | ||
22 | + fontLoaded ? <Main /> : null | ||
23 | + } | ||
24 | + </Provider> | ||
25 | + ) | ||
12 | } | 26 | } |
13 | 27 | ||
14 | export default App; | 28 | export default App; |
... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
searchGuide/assets/font/NanumBarunGothic.ttf
0 → 100644
No preview for this file type
No preview for this file type
-
Please register or login to post a comment