Skip to main content

Questions tagged [jsx]

For questions about the JSX syntax used by React.js, Vue, and other front-end JavaScript frameworks that allows inline XML literals to be used in JavaScript to describe HTML elements. If your question is about Adobe's extended implementation of JavaScript (ExtendScript) which is at least five years older than React.js, use the [ExtendScript] tag instead.

0 votes
1 answer
35 views

NextJS App Router: How to access child component properties in layout?

To make use of the layout feature in the NextJS's App Router, I want to dynamically update the page title (<h1> tag, not metadata like <title>) on the layout depends on what the page ...
Jamie Phan's user avatar
1 vote
1 answer
33 views

Is there a way to redirect to different links depending on the user's status?

import React from "react"; import { Card, CardContent, CardDescription, CardHeader, CardTitle, } from "@/components/ui/card"; import Link from "next/link"; import { ...
Jean Mako's user avatar
3 votes
1 answer
79 views

Fixing Transparent Line Between Div with Clip-Path and Parent Div

A thin, transparent line appears between the triangular div and its parent div when zoomed. I believe this is likely caused by anti-aliasing in the browser. If there is a way to fix this, I would ...
Mr.Unknown's user avatar
0 votes
0 answers
20 views

How to Wrap FlatList rendered Items in a Fixed-Height Container in React Native?

I have a problem where I want to render a list of items using FlatList, but I expect a large number of items and want to wrap these items in a container with a fixed height. This is to save screen ...
Kalin Toshev's user avatar
0 votes
0 answers
11 views

Echoing from .jsx into Blade file. ReactJS & Vite

I've got a weird problem where I'm transferring blade.php code into .jsx, and in Blade, PHP's echo {{asset()}} and Blade's @ syntaxed code is referred to a lot. How would I go about putting it inside ....
Tyler Delmas's user avatar
0 votes
0 answers
20 views

How do I stop react-slick slider image from indefinitely expanding and fit the container?

I am trying to create an image slider / carousel inside of a box. I have got the carousel working, but the image is too small. Whenever the width is adjusted (or infinite is true) the image just ...
HelpImStuck's user avatar
0 votes
0 answers
15 views

integrating a MUI minidrawer in my react project

I want to try the MUI Mini variant drawer in my react project but it doesn't work : I created a react vite project , I installed the @mui/material and @mui/icons-material packages, and from the MUI ...
Amir Baroudi's user avatar
0 votes
1 answer
28 views

React app 'Encountered two children with the same key, `thumb-undefined`'

I'm trying to create a time slider in my react app and I can't beat this error below that keeps showing up in my browser console. bundle.js:21658 Warning: Encountered two children with the same key, `...
econobro's user avatar
  • 359
0 votes
1 answer
54 views

Showing intersection of a plane in a 3d shape with Three.js

I tried to animate with Three.js to show the intersection plane on a 3d object. In this example, I have used a cone as an example for the 3d object in the following code: import React, { useRef, ...
swiftenjoyer's user avatar
0 votes
4 answers
55 views

How to make text follow progress bar

How can I make my currentProgresstext follow the progress bar, for now it seems that setting progressWidth to 100 makes the text appear on the left (following the progress bar). And the progress bar's ...
user9132502's user avatar
0 votes
1 answer
35 views

Using an external function to fetch data in NextJS

I'm trying to limit repeated code by moving the code that fetches data to an external file. The fetchUserInfo I'm using uses the useEffect, useState hooks and as such needs to be a "use client&...
nome cognome's user avatar
0 votes
0 answers
24 views

Alter Javascript hash inline

My script is like this, TableCell has the one element sx which works like a stylesheet Material-UI https://mui.com/material-ui/api/table-cell/ var sx = {padding:"10px 0px 10px 0px",fontSize:&...
whitebear's user avatar
  • 12k
1 vote
1 answer
38 views

HTML Table is not overflowing its container

I am trying to make an html table overflow its container to have a scrollbar on mobile, but it is not working. Here's the code: export default function Stats({ pokemon }: { pokemon: PokemonWithColor })...
Rafael's user avatar
  • 63
-1 votes
3 answers
45 views

React component state not being correctly set [duplicate]

I have the following useEffect hook in a react component that fetches data from a api. http is an axios instance. I have a react use State hook const [inputsData, setInputsData] = useState(false);. ...
DoINeedANameTho's user avatar
0 votes
2 answers
32 views

React - component content not pulling through

I'll admit I'm relatively new to React but I'm simply trying to pull through content from a Child component to the parent App component but it's not pulling in the content and I can't figure out why. ...
Chobbit's user avatar
  • 493

15 30 50 per page
1
2 3 4 5
622