Recreating Facebook’s Recoil library

This weekend I decided to play with the new kid on the block – Facebook’s Recoil library for managing state. I did the trivial counter example to see how it works. It’s pretty simple idea so I wondered how much it takes to replicate its features. I found the exact answer – 70 lines of code. Obviously, my implementation didn’t cover everything but it was fun so I decided to share my findings.

(A side note: I did not look at the code of Recoil. I didn’t want to be bias on how to write my version.)


This content originally appeared on Krasimir Tsonev - blog and was authored by Krasimir Tsonev - blog

This weekend I decided to play with the new kid on the block - Facebook's Recoil library for managing state. I did the trivial counter example to see how it works. It's pretty simple idea so I wondered how much it takes to replicate its features. I found the exact answer - 70 lines of code. Obviously, my implementation didn't cover everything but it was fun so I decided to share my findings.

(A side note: I did not look at the code of Recoil. I didn't want to be bias on how to write my version.)


This content originally appeared on Krasimir Tsonev - blog and was authored by Krasimir Tsonev - blog


Print Share Comment Cite Upload Translate Updates
APA

Krasimir Tsonev - blog | Sciencx (2021-02-07T21:52:56+00:00) Recreating Facebook’s Recoil library. Retrieved from https://www.scien.cx/2021/02/07/recreating-facebooks-recoil-library/

MLA
" » Recreating Facebook’s Recoil library." Krasimir Tsonev - blog | Sciencx - Sunday February 7, 2021, https://www.scien.cx/2021/02/07/recreating-facebooks-recoil-library/
HARVARD
Krasimir Tsonev - blog | Sciencx Sunday February 7, 2021 » Recreating Facebook’s Recoil library., viewed ,<https://www.scien.cx/2021/02/07/recreating-facebooks-recoil-library/>
VANCOUVER
Krasimir Tsonev - blog | Sciencx - » Recreating Facebook’s Recoil library. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2021/02/07/recreating-facebooks-recoil-library/
CHICAGO
" » Recreating Facebook’s Recoil library." Krasimir Tsonev - blog | Sciencx - Accessed . https://www.scien.cx/2021/02/07/recreating-facebooks-recoil-library/
IEEE
" » Recreating Facebook’s Recoil library." Krasimir Tsonev - blog | Sciencx [Online]. Available: https://www.scien.cx/2021/02/07/recreating-facebooks-recoil-library/. [Accessed: ]
rf:citation
» Recreating Facebook’s Recoil library | Krasimir Tsonev - blog | Sciencx | https://www.scien.cx/2021/02/07/recreating-facebooks-recoil-library/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.