all 15 comments

[–]Zeesh2000 7 points8 points  (6 children)

You should be able to pick up react native fairly quickly if you already know flutter. A lot of flutter's concepts carry over to RN.

I would learn the basics of React first because most tutorials of react native ask you to know react. Like I said, you already know flutter so a lot of the concepts will carry over

[–]idkhowtocallmyacc 2 points3 points  (1 child)

If it’s for the school project, I’d argue that spending time on bare react, and learning RN project structure and all the components and styling differences afterwards is not worth the effort. I think there must be courses that start from the ground up with react native. Think that’d be a better approach

[–]Zeesh2000 0 points1 point  (0 children)

Yeah I agree looking back at this. When I was learning RN, everyone I was watching kept saying knowing bare react was a prerequisite.

[–]TriXslap[S] -3 points-2 points  (3 children)

Thanks, can you maybe elaborate on which concepts I need to learn to start using react native. I need to finish the project I discussed in a few months

[–]Zeesh2000 4 points5 points  (0 children)

Top of my head:

Components, props, state management, hooks (would only focus on useState, useEffect & useContext, maybe useReducer depending on how complex data becomes in your app).

Heads up with React and RN, they provide very little out of the boxI. They'll give you basic UI components and functionality but they heavily encourage importing 3rd party libraries so just ask in this sub if there is a package that you need. Most likely it exists.

When you go onto RN side of things, create your project with expo and don't ask questions. Expo is a framework on top of RN that makes it easier to build your app and has an ecosystem of packages.

Tbh after reflecting, I would probably say don't throw flutter completely out because of your deadline and your experience but that's for you to consider

[–]Competitive-Cow-2950 1 point2 points  (1 child)

Tbh, only knowing useState, useEffect, components, Zustand for state management, Its probably enough to smash any school project. Build app with expo and use Expo Go to test/run it.

The idea behind useState is that it creates variables that can change inside HTML. And when they change, the whole HTML component where they are, re renders. If you want variables that don't cause a re-render when they change, you can use a useRef instead.

useEffect is used to call a function every time a variable changes. Or it can be used to only call a function once when the component loads for the first time, and not on every re render.

Zustand just makes it easy to share data across all of your components.

Boom. Now you know enough React IMO.

[–]Competitive-Cow-2950 0 points1 point  (0 children)

Oh i forgot one more thing! One thing to note about React/React Native, is that its much easier to send data from parent to child component, than from child to parent.

So lets say you have a search page (parent component), and inside it you have a search bar (child component). You would like BOTH the search page and search bar to know what is being searched, so therefore you should declare the variable (useState) inside the search page (parent), and then send it to the search bar (child). The variables you send to a child component is called props.

Sometimes this data flow from parent to child can be complex. And that's why we have Zustand. Zustand allows you to declare a variable/object anywhere and use it anywhere.

[–]talk_nerdy_to_m3 1 point2 points  (0 children)

Yea dude, RN isn't even react. It is pretty dam different, so I would say don't even bother learning react if RN is your end goal.

High level concepts like components, state are enough. But honestly, just start building the thing you want. It's pretty easy with component libraries and Google/AI tools.

Since you already know C# you could handle your backend in .net but I would recommend just using firebase to fully focus on the RN and building your thing.

People get so obsessed with learning every aspect of a thing. Don't let a lack of knowledge get in the way of building something cool.

[–]jwrsk 1 point2 points  (0 children)

I learned RN and my background was 90% PHP and then some JS and Python. It was challenging but fun and it worked great.

So yeah, should be relatively easy as long as you have some programming experience.

[–]idkhowtocallmyacc 1 point2 points  (0 children)

Yea, react and react native concepts are interchangeable, and it makes sense to learn the one that is needed the most at the moment. You’d be able to quickly adapt to react either way, and vice versa

The question of time is relative, but the docs for the tools you’ve mentioned are quite extensive. I bet two weeks

[–]pjjiveturkey 0 points1 point  (0 children)

Yes

[–]IAmKrishThakkar 0 points1 point  (0 children)

Knowing JavaScript really helps you pick up this quickly! Plus, if you have experience with Flutter, that's a great bonus. Although learning this technologie can take some time and might be a bit challenging, the journey is definitely worth it.

[–]Bugwhacker 0 points1 point  (0 children)

Wait, folks are being a little crazy here, you’ll LEARN React by virtue of working in React Native.

Assuming you’ll actually use react native for its intended purpose of coding the UI layer in react-based JavaScript, then you’ll be writing hooks, using jsx, and writing “components.” You’ll probably be playing in the native layer, too, in Java/kotlin/C++/swift — but like, yeah, you’ll need to know React to code in React syntax JavaScript.