Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 5 years ago.
Improve this question
I'm about to choose whether to use React Navigation or to use React Router Native, I thought that React Navigation is better, but then I found some feedbacks like this react navigation issue, ps: React Router Native has similar API to React Router which seems very simple, I'm still lost! I need an advice
In my experience React Navigation works like a charm. It uses native-alike layouts if you don't wanna create your own, and let you customize them via props as you wish. It also lets you navigate inside functions without the need of redux actions, which i think are a must in React Router.
The main problem of React Navigation is its documentation, which is pretty lackluster. It has no complex examples, only simple stuff, so you have to lurk a little bit to do some stuff if your app starts getting complex, with a lot of nests.
Even so, the only hard to solve problem i really had with React Navigation was when i had a Stack Navigator (2nd) inside a Drawer Navigator which was nested inside a main Stack Navigator (1st), which back then wouldn't let me change the main header from within the 2nd Stack Navigator. This could be worked around by putting the 2nd Stack Navigator directly inside the main one.
Related
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 6 months ago.
Improve this question
I have question about the correctness of using styled components or another type of css styling in react
I prefer to use styled components in my projects. I agree that ionic components have many functionality out the box that help me work with native platform correctly
but for example ion-text is useless for me because it havent got support for font-size, font-weight in variables.css
so I prefer to create my custom TextComponent by styled components lib.
and there are many cases in my project when comfortable for me to use styled-components instead ionic components
so... the question
does use styled-components effect on my project? Are there some problems of using styled-components instead ionic components
or it will do no effects on my projects and there is no reason to use only ionic components for my UI?
There is no such specifications to use ionic tags only, as you mentioned ion-text.
Mostly ionic components are pre-styled to fit /adjust itself in mobile view as well.
If anyone uses custom styled components/tags considering mobile view and functionality in concern, it don't affect your mobile view.
Just use relative parameters like %, rem etc for designing, it helps in maintaining the view for mobile.
So conclusion is, you can use custom components,it will not affect your project.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 2 years ago.
Improve this question
I'm learning ReactJS, I know that react is about declaring the way something should render, giving it some data and poof, when the data changes, it renders those changes.
But if I want to manipulate the DOM, an example change a color, create a accordion, make animations, add and remove a class, etc.
React can do that? Could I migrate my jQuery projects to Reactjs without any problem?
There are many approaches for that task, a complete list is here in the official Docs. Either use React as a Wrapper on top of your jQuery Application or Translate your jQuery App to a React App.
From the official Docs
React is unaware of changes made to the DOM outside of React. It determines updates based on its own internal representation, and if the same DOM nodes are manipulated by another library, React gets confused and has no way to recover.
This does not mean it is impossible or even necessarily difficult to combine React with other ways of affecting the DOM, you just have to be mindful of what each is doing.
The easiest way to avoid conflicts is to prevent the React component from updating. You can do this by rendering elements that React has no reason to update, like an empty .
Here is a medium article that may help you.
How-my-team-converted-our-website-from-jquery-to-react-in-small-steps
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 2 years ago.
Improve this question
I have JavaScript library which i using in Cordova applications.
Library create drawer with HTML/JS/CSS and drag events.
https://github.com/roman-rr/cupertino-pane
I want use this library/code in React Native.
Is there any simple ways to convert html/js into react component + some logic ?
Can i use some type of bridge and same package ?
HTML elements require browser environment to run and react-native requires the native component to load on the respective native platform so you can't use HTML elements directly in react-native app.
I have looked at your provided URL and it requires browser environment so you can't use it but here is a replacement for this component is react-native
https://github.com/jeremybarbet/react-native-modalize
You can use JS logic for making calculations you but can't use UI So you have to use native component plus CSS that you have, It requires small changes too or you can use Styled-component if you don't want to make many changes with CSS
https://styled-components.com/docs/basics#react-native
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
My question is about the standards of React and JSX. I am unsure how to formulate a page using React. Do I break down my page into components and render everything through JSX? Or is it a combination of HTML with rendered components strewn throughout?
I have been unable to find any succinct response to this question, but from what I have gathered, is that I break the webpage into only components.
It's a combination of HTML with rendered components strewn throughout. You can however also have only one master "component" to render the entire app and it's "sub" components rendered within.
I don't think the term component is the best one here but I get what you mean rather I think you mean React Element.
Generally it is preferred and easier to just use React Elements where you need React eg for a search bar and have everything else in HTML.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 1 year ago.
Improve this question
I used react on several of my project is that it was well passed, but it is last time I saw that there is a react-hot-reload
What is react-hot-loader?
What is its use?
difference between Hot Module Replacement in Webpack and React Hot Loader ?
What is the advantage it will bring to the workflow?
how it works behind
can anyone explain me plz :)
React Hot Loader is a React library used to edit your code and automatically reflect that change in your running app while keeping the components mounted, which means you don't need to refresh your browser and you won't lose your current state. It's pretty convenient as you won't have to go step-by-step to test a specific state in your app every time you make a change in the code.
Your workflow would be faster, simpler and more comfortable.
Here's a live demo: http://gaearon.github.io/react-hot-loader/
Edit: React Hot Loader is now deprecated, use React Fast Refresh