I’m (re)training myself to do web development, both as a career move and just because I find this stuff fascinating – albeit intensely frustrating.
So after a few months learning all about the latest trends in the React/Redux/ES2015 world, I took a simple Rails blog and added asynchronous login/signup and real-time comment previewing with async submission. It’s here:
And the code is here:
It works for a while, and then something will happen that I don’t fully understand, and it won’t work in a couple areas:
Facebook login will get out of sync. Checking login status will stop working, and then instead of launching the login dialog, I’ll just get a blank window. Closing the blank window will either log the user in under his/her Facebook account or just as “undefined”, seemingly based on data coming from a local facebook cookie. But it’s fair to say that I don’t get what Facebook’s js sdk is doing.
If there’s a server error, subsequent comment submissions stop appearing at the end of the comments list where they should. (The comments will typically start appearing at the top of the list, but sometimes, it’s been in the middle; I haven’t isolated the circumstances that lead to one outcome vs. the other.) I think this has something to do with how I have my comments reducer set up.
If anyone has any ideas that might help me resolve these issues (or, for that matter, any other issues you discover), I’d love to hear them.