Category "reactjs"

Why is localStorage getting cleared whenever I refresh the page?

Like the title says, the localStorage I set registers the changes made to the todoList array and JSON.stringifys it; however, whenever I refresh the page the ar

How can I get a React application to send SQL queries to an Oracle database and retrieve results?

Background: I need to create a web application that connects to an Oracle database hosted by my university through a VPN. The app does not have to be hosted onl

ACE Editor Autocomplete to open on `.`

If you enable live autocomplete, the tooltip opens up as you type things. However, it will never open up on pressing . until you type something else after. So

useState vs. useEffect - setting initial value

I have two basic questions about React: In order to assign an initial empty value to a piece of state (let's say player) in a functional component, are the foll

Link tag inside BrowserRouter changes only the URL, but doesn't render the component

I am building a Netflix clone application, and I am using react-router-dom v5 to switch between different pages. However, when I click the Link tag in Navbar.js

how to add external library to reactjs?

what are the various options to add an external JS library to reactjs component? for example, if we have any library file such as example.js and it is used by o

Suggestions for rate limiting using Axios

I'm using react with axios for accessing api from cryptocompare. Api has limit of 15 call per second. Now after 15 api call I'm getting error of "Rate limit e

Remove Y Axis and its grid lines

Im using react-google-charts This is my chart code <Chart chartType="Bar" loader={<div>Loading Chart</div>} data={[ ["", "Credit", "D

grid-template-columns is not working in React 18

Major Update to the Question(7th May): When I am using my arrow keys, I could see all of the three cards but still the same is as big as it doesn't fit on the s

How to redirect to external url onClick? in React

I'm using react-router which means i'm storing routes in app.tsx file. I have cards components that need to redirect to an external url onClick. So my question

Difference between Ant Design form.setFieldsValue and initialValues prop

As the title states. What is the difference between the two? 1. import { Form } from 'antd'; const Components = () => { const [form] = Form.useForm(); f

using react router with next.js

I am learning how to use Next.js/React for my application. I am currently researching the topic of routing and I had a few questions. I know that you can use re

js chunk being served with wrong mime type in react app

I have a react app (with routes handled by react-router) with some components lazily loaded deployed on heroku(free plan), it is served by this express server:

Show total number of selected filters array of items in React

I have the following problem. In widgetFilters array (length===3) i want to show the numbers of selected items in the header of the Filter. const [selectedFil

I can't figure where is the problem with my graphql request

I'm getting bad request code every time i try to send data query in graphql, and I can't figure if the problem from the resolver or from the input, below is th

I'm using ThirdWeb to create an app. However I'm getting a babel error that I'm not able to fix

The code causing the error is the import line which goes:import { ChainId, ThirdwebProvider } from "@thirdweb-dev/react";. This is the error message: ./node_mod

Horizontal scrolling in mobile view iOS

I have a horizontal gallery overflow-x: scroll that is choppy only in iphone/ipad view (Tested in Androids scrolls fine). I've seen some stackoverflow uses -web

Horizontal scrolling in mobile view iOS

I have a horizontal gallery overflow-x: scroll that is choppy only in iphone/ipad view (Tested in Androids scrolls fine). I've seen some stackoverflow uses -web

How to make Material UI v1.0 Dialog background transparent?

I am trying to make put a CircularProgress inside a dialog box. But the dialog box background is white and cannot be set to transparent as in earlier version -

Next.js, using random properties without triggering "did not match on server/client" error

I'd like to randomly generate the id property of form inputs, to prevent them from potentially conflicting with other inputs with the same id. This could happen