476,579 questions
Best practices
0
votes
1
replies
12
views
Is it an anti-pattern to fetch user data inside login mutation with tanstack query?
Im using expo with tanstack query and im trying to design a clean authentication flow.
My backend login endpoint only returns an access token(and expiration info), not the user object. So after login ...
0
votes
0
answers
22
views
A framer motion animation on an element entering a container with overflow:auto does not work
When trying to move items from container A into container B, the animation on the item that is being moved is only visible when entering container B. This is happening because the container B has a ...
Advice
0
votes
4
replies
33
views
Need help regarding open source contribution as a beginner
I am in a phase where I select a repo that is perfect for me. A problem arises when I pick an issue from the repo, then I go blank on how to approach it. So my main question is how to solve that issue,...
Advice
1
vote
3
replies
29
views
What is better to use in terms of performance && or <Activity>?
React 19.2 introduces a new <Activity> component that addresses issues related to content hiding during conditional rendering. I won't go into too much detail, but my question is: Which is ...
-1
votes
0
answers
32
views
MUI DataGrid - Server-side row grouping with paging
When using a MUI DataGrid with paging and grouping, we expect the group headings to respect the page size. However, the items within the group do not, and all items are displayed.
What is the best way ...
0
votes
1
answer
64
views
Why do I need to refresh my page to see changes in UI after updating watchlist, even though the database updates correctly?
I'm building a stock dashboard using Next.js 13 (App Router) with React Server and Client Components. I have a "watchlist" feature where users can add/remove stocks, and the changes are ...
-1
votes
0
answers
15
views
Forge Viewer (APS) v7: How to enable "Geometric" Box Selection (ACC style) instead of default Pixel-Based selection?
Context: I am implementing the Autodesk Platform Services (Forge) Viewer v7 in a React application. I have noticed a significant difference in behavior between the default embedded viewer and the ...
-4
votes
0
answers
40
views
Invoking React.js app from servicenow form [closed]
I have created a react.js app to query my architecture diagrams and assist in incident troubleshooting. I am trying to embed this in Servicenow form where the support engineering looks at an open ...
-1
votes
1
answer
85
views
Getting the client component async error: how to rewrite this Next.js client component with useEffect? [closed]
I'm currently following a Next.js/Sanity CMS course on Udemy. I ran into an error that the lecturer doesn't address while working on the product page that appears after you click on a particular ...
0
votes
0
answers
82
views
I am trying to create a custom family tree layout using D3.js (without d3.tree) and manual positioning [closed]
Requirements
1.All sons must be left aligned
2.All daughters must be right aligned
3.Each child’s entire family (child → spouse → descendants) should be treated as one vertical block
4.When the ...
1
vote
0
answers
110
views
Why does useEffect placement relative to an "unreachable" early return change child component re-render behavior? [closed]
I have encountered a very weird behavior of useEffect and unreachable early return. See here:
"use client";
import React, { useState, useEffect } from "react";
import { useForm } ...
0
votes
0
answers
90
views
Next.js production error: Failed to find Server Action "x" [closed]
I have a Next.js 16 application that is self-hosted on a VPS. I’m encountering the following error in production logs:
Error: Failed to find Server Action "x". This request might be from an ...
1
vote
1
answer
101
views
Infer params type from prop value
I have a message component that looks like this:
type MessageProps<
ParamList extends Record<string, any>,
K extends keyof ParamList
> = {
navTo: K;
title: string;
desc:...
2
votes
1
answer
58
views
Custom use API Hook Error: Could not find react-redux context value; please ensure the component is wrapped in a <Provider>
I'm trying to learn how to use react-testing-library and having trouble getting started with some of my components. I keep receiving the error in the title, pointing at custom API hooks in the file.
...
0
votes
2
answers
61
views
Specificity for text color and border color in Tailwind CSS [duplicate]
I got a chunk of code as shown below:
<span className={`
px-2 py-0.5 rounded-full text-gray-500 border border-gray-300
${displayType === 0 && "border-gray-600 text-black"}
...