mirror of
https://github.com/kusti8/proton-native.git
synced 2026-05-15 14:15:50 -06:00
[GH-ISSUE #83] Sharing code between proton-native and react-native #50
Labels
No labels
bug
documentation
enhancement
libui issue
pull-request
question
wait for libui implementation
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/proton-native#50
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @dchersey on GitHub (Apr 21, 2018).
Original GitHub issue: https://github.com/kusti8/proton-native/issues/83
Hi, thank you for your efforts in creating this framework!
I have an existing RN app that is under development and would love to add a desktop (Mac, windows, linux) target to it ... I understand I'd have to build new views but my redux actions, reducers, api, etc could all be re-used by them.
Any tips on how to structure the code so that I can keep it to one code base?
@kusti8 commented on GitHub (Apr 22, 2018):
When I used react Native, I mostly used ignite cause it came with a really good structure. I can't remember exactly what it was, but basically you have a folder for state changes, folder for API, folder for stateless pure components and then a folder for state full components. IMHO that would be how I would do it. If you're doing anything that requires differing libraries, make that a separate file.
Basically, separate the different parts of it and make it modular (same API) so that to convert, you just have to change the react Native components and props to proton native components and props.