Uh oh!
There was an error while loading. Please reload this page.
Add Kotlin code for "Communication Android" documentation - #3070
Conversation
facebook-github-bot
commented
Apr 11, 2022
Hi @junaidn! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at cla@fb.com. Thanks! |
✅ Deploy Preview for react-native ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
facebook-github-bot
commented
Apr 11, 2022
Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks! |
junaidn
commented
Apr 11, 2022
cortinico
left a comment
There was a problem hiding this comment.
Left a couple of nits 👍 Looks good overall
| override fun getLaunchOptions(): Bundle { | ||
| val initialProperties = Bundle() | ||
| val imageList = | ||
| ArrayList(listOf("http://foo.com/bar1.png", "http://foo.com/bar2.png")) |
There was a problem hiding this comment.
You can use arrayListOf here:
https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/array-list-of.html
| val initialProperties = Bundle() | ||
| val imageList = | ||
| ArrayList(listOf("http://foo.com/bar1.png", "http://foo.com/bar2.png")) | ||
| initialProperties.putStringArrayList("images", imageList) |
There was a problem hiding this comment.
I'd reword to:
val initialProperties =Bundle().apply {
putStringArrayList("images", imageList)
}| var imageList: ArrayList<String> = | ||
| ArrayList<String>(listOf("http://foo.com/bar3.png", "http://foo.com/bar4.png")) |
cortinico
left a comment
There was a problem hiding this comment.
Left a small nit. Other than that, LGTM 👍
Uh oh!
There was an error while loading. Please reload this page.
Co-authored-by: Nicola Corti <corti.nico@gmail.com>
cortinico
commented
Apr 13, 2022
Thansk for doing this @junaidn 🙏 |
This PR includes:
Sample code of Kotlin for
docs/communication-androiddoc.