Skip to main content
Filter by
Sorted by
Tagged with
0 votes
2 answers
2k views

i'd like to achieve open react-datepicker calendar on button click outside of this component with ref. It is working fine if its outside of conditional rendering. If i put into a condition statementm ...
J.Rautner's user avatar
1 vote
0 answers
236 views

I have a functional component that renders a div X or a divY depending if the props are undefined or not. Functional Component: const InfoHeader = (props) => { const {population, infected, ...
Jorge Guerreiro's user avatar
3 votes
2 answers
4k views

In my React code, I want to display several images in my folder. I have about 100 images and I don't want to import all of the images in different import statements. I want to import them maybe with ...
Utku Demir's user avatar
-1 votes
1 answer
1k views

Hi so currently i am trying to iteratively build tabs and the tabpanels to show it's information but i cannot get what i want to be displayed. i have a list of names for each name create a tab and a ...
teddy franco's user avatar
0 votes
0 answers
363 views

Ok, so first time question-asker here, but I'm having trouble rendering a class to a grid cell, then removing it. The idea is the grid is the floor, and the class represents a roomba moving around it. ...
hayesdev's user avatar
0 votes
2 answers
1k views

I am new to gatsby and server side rendering, although I've worked with react quite a bit before. I wrote a bit of code that checks for the window size and then renders either the nav or the mobile ...
Ren's user avatar
  • 171
0 votes
3 answers
215 views

The code does the following - if the item selected from the dropdown menu is 'pinpong' then it will show the content within the div container content In the second component if the item selected from ...
ohsoelisa's user avatar
2 votes
1 answer
524 views

I'm new to flutter. I have to render widgets according to an API response, which is JSON in a list. This is one of the custom widgets I have written for it. I have one for every row. Widget ...
ubermensch's user avatar
0 votes
3 answers
4k views

I'm using React with Material-UI. I'm developing a simple UI in a form of a dropdown menu. I'd like to control the rendering of the first row with condition passed as a prop. How can I use the ...
Richard Topchii's user avatar
6 votes
1 answer
2k views

I'm working on a react web application the problem that I have is that I'm doing a conditional rendering of the same component with different props but that does not unmount it then remounts it again ...
Boubekeur Alaa Eddine's user avatar
2 votes
1 answer
7k views

I have a button component that's supposed to change colors based on its status (passed in by props). The colors are stored in a css file. I read that the clsx npm is a good one to use, but I don't ...
for-84's user avatar
  • 21
0 votes
1 answer
52 views

I have used conditional rendering in the past but for some reason, it's working on one element here but not on another although they are both using the same JSON phrasing and the same type of ...
lukeet's user avatar
  • 511
0 votes
2 answers
1k views

I am building a ride sharing app to learn react-native. In order to publish a new Ride, I have a Modal which renders conditionaly on the step state and each step has a diferente UI. Like: let screen; ...
Tiago's user avatar
  • 121
0 votes
2 answers
749 views

Can you give me a hand with this expression . Basically what i am trying to say is If props.row.registered is true set disabled to be true or if is props.row.registered is undefined set it to false. &...
PandaMastr's user avatar
0 votes
1 answer
337 views

I've been wondering if there is a way to send a condition as a prop to a child component that needs some conditional rendering and its iterating a set of dynamic objects. Let's say I want one of those ...
Jose Peres's user avatar
2 votes
1 answer
6k views

I want to render a component based on props passed by the parent component, then in the children component i evaluate the props using switch statement. I was unable to get return element based on ...
Achmad Wahyu's user avatar
1 vote
1 answer
4k views

Trying to implement the overlay fullscreen menu with Vue.js, html/css/js is [this solution]https://www.w3schools.com/howto/tryit.asp?filename=tryhow_js_overlay2 But stuck with how to toggle div ...
Kimchi Rice's user avatar
4 votes
2 answers
17k views

there is a problem, I don't know how to implement the component technically correctly. I want to do conditional rendering of an element depending on the device screen. Example: if the screen is less ...
Евгений Морозов's user avatar
0 votes
3 answers
5k views

I'm building a small clothing store app in React, just to learn things. I implemented a filter by price section but I would want to be able to write a condition for the case in which there's no item ...
Andra's user avatar
  • 71
0 votes
1 answer
942 views

I am new to React Native. I am trying to render a button conditional on the value of a 'global' value. This is incredibly frustrating. Normally it would be a simple case of using an 'if/else' ...
Pangit's user avatar
  • 674
0 votes
1 answer
45 views

I'm trying to get a bit of react code to work and am struggling with conditional rendering. The following: <div id="table_holder" className="table-responsive mx-3"> <table ...
Quantipy's user avatar
2 votes
1 answer
2k views

I am using the following code to display a 'Home' page with a button on it in React Native...it is functional without difficulty: import React, { useState } from 'react'; import { Button, Text, ...
Pangit's user avatar
  • 674
1 vote
1 answer
52 views

*I am currently trying to figure out how to change the background image of my book--container--fiction. I have three different images and depending on the genre of the book I would like to change ...
webDesigner's user avatar
0 votes
1 answer
525 views

I'm trying to render component with an "Edit" button that is within the component. I decided to use conditional rendering in my code, but I can't seem to get it to work properly. Does anyone have ...
Taylor Phelps's user avatar
0 votes
1 answer
275 views

i have two value at dataindex: isOnline (true and false) , this time my render NavLink on both true and false , but i want only render on false value not with true value. Is there any possibility to ...
Raushan Singh's user avatar

1
3 4
5
6 7
9