react native 0.56.0
生活随笔
收集整理的這篇文章主要介紹了
react native 0.56.0
小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.
2019獨(dú)角獸企業(yè)重金招聘Python工程師標(biāo)準(zhǔn)>>>
0.56.0 更新日志
能力有限,如有問題,請(qǐng)包涵(哈哈)原文請(qǐng)點(diǎn)擊
歡迎 React Native 2018年6月份正式版的發(fā)布,超過53位捐獻(xiàn)者提供797次提交,非常感謝你們每一位。
在您閱讀本文的此刻,這個(gè)花費(fèi)了我們大量努力才能達(dá)到穩(wěn)定的0.56新版本有了一些重要的突破性的改變,這也是我們跳過4月份、5月份沒有發(fā)布的主 要原因,但是在未來我們計(jì)劃將繼續(xù)回到之前的每一個(gè)月做一次發(fā)布
更新亮點(diǎn)
- React Native 在0.56版本中使用Babel 7.,確保您的babel-preset-react-native package.json 依賴 ^5.0.1 或者更新。如果您已有一個(gè)版本庫(kù),請(qǐng)確保更新配置到Babel 7,因?yàn)锽abel 7是不向后兼容的,一旦0.56達(dá)到穩(wěn)定,我們將會(huì)把babel-preset-react-native@latest 的tag調(diào)到5.0.1
- Node 8 是需要的最小版本,現(xiàn)在允許逗號(hào)
- iOS 9 是最低版本要求,任何可以運(yùn)行ios 8的設(shè)備都可以升級(jí)到ios 9,開發(fā)人員如果讓他們的app支持ios 8,可以在Xcode-level 設(shè)置IPHONEOS_DEPLOYMENT_TARGET
- Xcode 9現(xiàn)在是最低要求的版本。我們建議使用Xcode 9.4,因?yàn)槲覀兪褂盟鼇磉\(yùn)行測(cè)試。
- Android項(xiàng)目現(xiàn)在使用編譯庫(kù)為Android 26 SDK。在這個(gè)版本中,API級(jí)別保持不變。2018年8月開始,提交給Play Store的新應(yīng)用程序最低需要的target 為API 26。您現(xiàn)在可以選擇API 26(或者更新版本)在您的項(xiàng)目中,如果有什么問題,可以在0.57.0發(fā)布之前告知我們,因我我們想最終確定Android API 26的支持。
- WebView默認(rèn)情況下只加載http(s) url,默認(rèn)情況下禁用地理定位。
- 為幾個(gè)組件增加了Flow types,我們將逐漸使用Flow代替PropTypes和運(yùn)行時(shí)檢查,在這個(gè)版本中,你會(huì)注意到許多關(guān)于Flow的改進(jìn)
- 修復(fù)新Xcode版本的項(xiàng)目設(shè)置警告,刪除不必要的console logging
- 現(xiàn)代化YellowBox。按近似值對(duì)警告進(jìn)行排序,按格式字符串對(duì)警告進(jìn)行分組,顯示堆棧跟蹤,顯示加載源映射的狀態(tài),支持檢查每個(gè)出現(xiàn)的警告,并修復(fù)bug。
- Prettier files!
- 修復(fù)大量的bug
提醒一下:Facebook內(nèi)部團(tuán)隊(duì)目前正在重寫一些核心架構(gòu)部分。這是一項(xiàng)正在進(jìn)行的工作,我們并不期望它可以在開源中使用,但是我們覺得有必要讓您知道這些提交提及的Fabric是什么。
新特性
- 更新 babelHelpers 使用Babel 7支持 - https://github.com/facebook/react-native/commit/fbd1beaf666be9c09a380784f8c0cd34ba083a6b
- FlatList is now Strict Mode compliant - https://github.com/facebook/react-native/commit/a90d0e3614c467c33cf85bcbe65be71903d5aecc
- 可以使用?.可選鏈接操作符 -https://github.com/facebook/react-native/commit/aa6f394c4236e5a4998c3be8ed61ec1bab950775
- 支持flexWrap: 'wrap-reverse' -https://github.com/facebook/react-native/commit/d69e55060fd76d91eccc45905d250a9fce4b2c49
- 增加Text屬性accessibilityTraits -https://github.com/facebook/react-native/commit/654435d1ed9e584e65fff601e1fa50591e042664
- 增加devDependencies模版支持 -https://github.com/facebook/react-native/commit/c4ab03a18e75e6ed55444b5d86f3ceee435b9a78
- SpringInterpolator 增加springDamping支持 -https://github.com/facebook/react-native/commit/1dde989919d2c272ca7fcaa5c4b2d9ee02c490a0
Android平臺(tái)
- CRLF build.gradle 支持使用react-native link link、-https://github.com/facebook/react-native/commit/843cfc3b202433aad9a236b1b623da7c45e1ac15
- 為安卓提供decimal鍵盤 -https://github.com/facebook/react-native/commit/5b7a817723e626453eedc800e71a4babd256218f
- 為PopupMenu添加消失方法 -https://github.com/facebook/react-native/commit/353c070be9e9a5528d2098db4df3f0dc02d758a9
- 實(shí)現(xiàn) Image.defaultSource -https://github.com/facebook/react-native/commit/b0fa3228a77d89d6736da6fcae5dd32f74f3052c
- 支持Iamge resizeMode=repeat -https://github.com/facebook/react-native/commit/0459e4ffaadb161598ce1a5b14c08d49a9257c9c
- Yoga: Add back deprecated getParent methods for non-breaking API change -https://github.com/facebook/react-native/commit/c3c5c3cbce24a31f73ae6339e377ee76ca6401ad
iOS平臺(tái)
- Xcode 9.4 and iOS 11.4 運(yùn)行tests -https://github.com/facebook/react-native/commit/c55bcd6ea729cdf57fc14a5478b7c2e3f6b2a94d
- 增加支持 Homebrew-installed Node -https://github.com/facebook/react-native/commit/0964135a178b459e06b44a49a4ecb0dd6c5bec9b
- 增加textTransform style 支持 -https://github.com/facebook/react-native/commit/8621d4b79731e13a0c6e397abd93c193c6219000
- 為 Swift使用RCTBridgeModule.h添加了文檔 -https://github.com/facebook/react-native/commit/ca898f4367083e0943603521a41c48dec403e6c9
更改:
- 更新 Upgrade React Native to Babel 7 -https://github.com/facebook/react-native/commit/f8d6b97140cffe8d18b2558f94570c8d1b410d5c
- 創(chuàng)建新項(xiàng)目react-native init 將使用Babel 7 -https://github.com/facebook/react-native/commit/e315ec9891eb0bcb51afb0e797dbd49aa8f9ac71
- 限制 WebView 僅能加載http(s)類型的URLs: -https://github.com/facebook/react-native/commit/634e7e11e3ad39e0b13bf20cc7722c0cfd3c3e28 https://github.com/facebook/react-native/commit/23f8f7aecb1f21f4f5e44fb9e4a7456ea97935c9
- Node 8 是最小需要版本 -https://github.com/facebook/react-native/commit/c1e6f278237e84c8ed26d3d2eb45035f250e2d40
- 升級(jí)react 到v16.4.1,同步react Renderer 修訂ae14317 -https://github.com/facebook/react-native/commit/72d22e8828feece1500487b9c28bb1df21b090f5
- 更新項(xiàng)目模版的Flow配置,修復(fù)由于刪除了@providesModule而引起的Cannot resolve module X的問題 -https://github.com/facebook/react-native/commit/843a433e87b0ccaa64ab70d07e22bffbabad8045
- 升級(jí)Flow 到 v0.74 -https://github.com/facebook/react-native/commit/3bed272a620ac806a6142327013265ea8138641a
- 更新 Flow 定義 -https://github.com/facebook/react-native/commit/f8b4850425f115c8a23dead7ec0716b61663aed6
- 更新 Prettier to v1.13.4 -https://github.com/facebook/react-native/commit/29fb2a8e90fa3811f9485d4b89d9dbcfffea93a6
- 更新 Jest to v23.1.0 -https://github.com/facebook/react-native/commit/536c9372692712b12317e657fc3e4263ecc70164
- 更新 Metro to v0.38 -https://github.com/facebook/react-native/commit/d081f83a0487ffbc7d19f8edc7532611b359dfc6
- 現(xiàn)代化 YellowBox -https://github.com/facebook/react-native/commit/d0219a0301e59e8b0ef75dbd786318d4b4619f4c
- 將invariant/warning 設(shè)置為requiring的黑名單,不允許 requiring invariant/warning -https://github.com/facebook/react-native/commit/521fb6d041167ec8a8d0e98ac606db1f27f0c5c8
- 移除 Native 的Validation屬性 -https://github.com/facebook/react-native/commit/8dc3ba0444c94d9bbb66295b5af885bff9b9cd34
- Add $FlowFixMe to invalid prop accesses where Flow wasn't complaining before -https://github.com/facebook/react-native/commit/f19ee28e7d896aaacf26c6f850230019bdef0d3d
- 為Image創(chuàng)建Flow屬性 -https://github.com/facebook/react-native/commit/8bac869f5d1f2ef42e707d0ec817afc6ac98b3b2
- 為SegmentedControlIOS、ProgressViewIOS、PickerIOS、Switch、Slider、RefreshControl、ListView、TextInput、TouchableBounce、TouchableOpacity、TouchableHighlight、TouchableWithoutFeedback、ScrollView、DatePickerIOS、KeyboardAvoidingView、ActivityIndicator創(chuàng)建Flow屬性
- TouchableBounce、ScrollView、ListView、Text、RTLExample、AppContainer、Slider 移除 $FlowFixMe
- StyleSheet:支持border維度value -https://github.com/facebook/react-native/commit/3e3b10f4044ada7b523d363afb614720468c217f
- Update react-devtools-core and plist to include security fixes reported by npm audit -
- Switch、Slider、ActivityIndicator、RefreshControl、KeyboardAvoidingView、DatePickerIOS、Text 更新到 ES6 Class
- Replace context.isInAParentText w/ React.createContext
- Cleanup Text implementation
- Switch Text to React.forwardRef
- Switch View to React.forwardRef
- Update uses of genMockFunction and genMockFn to fn in tests
- Make ViewProps exact
- Spread TVViewProps into ViewProps instead of intersection
- Allow trailing commas 允許在函數(shù)參數(shù)上添加尾逗號(hào)
- Use let/const -https://github.com/facebook/react-native/commit/8f5ebe5952d0675b463137103a82f3fb0c26ae0d
- ...太多了,點(diǎn)擊查看更多
轉(zhuǎn)載于:https://my.oschina.net/KJhulinhua/blog/1858111
總結(jié)
以上是生活随笔為你收集整理的react native 0.56.0的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 写一个脚本定时自动备份mysql到指定目
- 下一篇: web页面版权部分的显示问题