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.
Related
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 7 months ago.
Improve this question
I was searching for a ready-to use web component for my Vaadin&Spring Boot application, and faced some questions.
As a person who does not into JS and frontend at all, i'm struggling in integration of those components. Currently I'm interested in this one: https://vaadin.com/directory/component/bluewatertrackspaper-countries/overview. I simply do not know what to do after adding a dependency via Maven. Could someone explain a way how to use those components similarly to default Vaadin components, using java classes?
Unfortunately the webcomponent you linked is built with polymer2. You can't use it in Vaadin 14+, except if you are running it in compatibility mode which I don't recommend.
It's easier to do it in Java with a Combobox.
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 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 4 years ago.
Improve this question
I'm starting a new react native app.So what would be the best way for doing the UI? I tried a ui-kit but it seems to be more complicated than building from scratch. So please guide me for an efficient way.But I think it will not take much time for building the app using an ui-kit right?I am confused please guide me.
You don’t need a UI Kit if you code UI on your own! It is actually
good to code your own UI because you have complete control over the
code.
UI kits do help a lot by reducing the development time but sometimes
you might need more customisation than a UI kit offers! So It is
always good to code your own UI coupled with smaller component
libraries.
Here are some of tool kits that are available and actively maintained by the community itself. These tool kits will not only save up your tons of development time but also help you to provide consistent design over different devices.
NativeBase
React Native Material Kit
Shoutem UI
React Native Elements
React Native UI Kitten
Nachos UI
React Native Gifted Chat
If none of these choices float your boat, you can always learn how to style components from scratch yourself.
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 years ago.
Improve this question
I am doing some research for a large project which will use reactJs and all html elements will be converted to React Components.
As we all know, css has a big problem with globals so there is a lot of posibility of css conflicts.
There are lots of different options for this including:
Atomic Design
SMACSS
OOCSS
or using libraries like:
Radium
React Style
React Inline
jsxstyle
React JSS
React Inline CSS
React Look
React Statics Styles
All of these have something good but at the same time all are under experiment and missing things.
In other words none of them solve all the css problems in react component styling or some just try to solve a problem that isn't there.
After trying all of them I am half way thinking that I should just link to common styles css files and have a css file specific to each component and target that css file from within the component.
Has anyone here had experience in styling react components in large project and have any feedback on it or suggestions?
I simply cannot make up my mind on just using straight css or javascript for this.
Is there anything I've missed to research?
There's nothing wrong on including CSS with your solution, SASS and LESS are awesome.
However, I personally like inline styles a as a plain JS object because it gives you the whole power of JS, so you can be as dynamic as you want, make the calculations all the calcs you need without pre-processing css, etc...
The React team has been investing in this for a while (React Native already uses this by default) here's a to React Native Styles, and a Presentation from a Facebook engineer, and a Proposal from the reactjs/react-future repo, and there are nice libraries like Radium which helps you a lot.
CSS in JS is surely getting better each day, so yeah, I'd advise on making that jump. :)