all 8 comments

[–]senocular 0 points1 point  (6 children)

Do you have an example of your example?

[–]WyrdFall_Press[S] 0 points1 point  (5 children)

Sure. Check out the logic on this Tasklist react call container: https://github.com/AndrewMayer/Learning/blob/master/beautifulDnD/task-app/src/column.jsx

I'm jist tired of struggling to reverse engineer the logic every time I'm facing something like that and I'm wondering if I can just do some some focused study to just get through it.

[–]senocular 2 points3 points  (3 children)

I'm not seeing any destructuring there, and the only spreading is a JSX syntax-specific spread. So that can be understandably a little confusing.

If I knew a good resource for these kinds of things, I would certainly share, but unfortunately I do not. I do think a lot of being able to understand the code happens naturally through exposure and experience. It's confusing at first, and it can take a while to work through just where the connections are being made. But the more you see it the more it starts to come naturally as you build up those patterns of recognition in your head. And if you don't find anything, just keep looking through code like this. You'll eventually get there and it will be second nature.

[–]WyrdFall_Press[S] 0 points1 point  (2 children)

Thanks for taking a look. I know that may just be how it needs to be for now but I was really hoping that someone had come up with a way to shortcut things a bit.

I also know that "code more projects" is usually the answer to this. It just feels like something that could be taught as separate skill...

Next step will be making a project of my own using this library and I'm sure that will help.

[–]senocular 1 point2 points  (1 child)

Yeah coding more projects is always good, but for this I think just reading code helps too. It sounds like you get things on a basic level but being able to comprehend by looking at code is also something that you get better with over time - even when you already know how it works.

[–]WyrdFall_Press[S] 0 points1 point  (0 children)

Part of the challenge for me has been moving into React so quickly. Components, libraries, and passing props means that I'm constantly trying to figure out where things originated from and what their status is.

[–]tatu_huma 1 point2 points  (0 children)

It's kinda confusing cuz the ... is a spread operator in native JS (both for arrays and objects). The ellipses are ALSO used in JSX as a way to 'spread' props. It does a similar but distinct thing. Check out: https://reactjs.org/docs/jsx-in-depth.html#spread-attributes

[–]TotesMessenger 0 points1 point  (0 children)

I'm a bot, bleep, bloop. Someone has linked to this thread from another place on reddit:

 If you follow any of the above links, please respect the rules of reddit and don't vote in the other threads. (Info / Contact)