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

I have this code where I've updated an object in React. When you click "Most upvoted", it takes an object, sorts it by votes, and then updates the state with it. The problem is, it won't ...
CodeNinja's user avatar
0 votes
0 answers
58 views

My Goal: In the following minimal code, I have MyMainInputWidget and YearInputWidget as input capturing widgets which are required. I don't want to call any provider methods within the YearInputWidget ...
rusty's user avatar
  • 1,263
0 votes
2 answers
110 views

I am using DropdownSearch with lazy loading inside a modal bottom sheet in Flutter. The list of items is fetched using Bloc (LocationMasterCubit), and I am handling infinite scrolling to load more ...
elvril's user avatar
  • 1
1 vote
0 answers
30 views

I'm having a weird performance about how onPressed function of my button to show and hide a sidebar is working. I have a stateful widget with a PageController to manage the pages when I click in my ...
DaveBit's user avatar
  • 11
1 vote
1 answer
47 views

I have a UI that uses http to get data from CoinApi.io. This async call populates a map that is in turn used to update the SliverGrid. This is based on a currency selection from a Cupertino app. What ...
Zeles's user avatar
  • 11
0 votes
0 answers
33 views

Currently, my screen is a column has multi widget like this: Column( children: [ FutureBuilder(future: ft1, builder: builder), FutureBuilder(future: ft2, builder: builder), ...
Dat Minh's user avatar
2 votes
1 answer
66 views

i have array of objects state that hold users objects, when user clicks add button it adds a new empty object to the state setUsers([...users, newRow]); when user upload image i want to add the image ...
Morgana Freeman's user avatar
0 votes
0 answers
52 views

here is my code late FocusNode fcMa, fcViTri; @override void initState() { super.initState(); fcMa = FocusNode(); fcViTri = FocusNode(); fcMa.requestFocus(); } @override ...
Dat Minh's user avatar
0 votes
3 answers
51 views

I understand that setState is asynchronous, but does it explicitly wait for all other code to be executed before it completes (even setTimeout with delay)? I've been trying to increment a counter ...
milance78's user avatar
1 vote
2 answers
286 views

I am not sure exactly when setState triggers the rebuild in Flutter. I have some text on a screen that I update with setState. It rebuilds nicely. Here is the code: setState(() { futureWait = "$...
rjapenga's user avatar
  • 277
-1 votes
2 answers
55 views

setState function in the custom_dialog page dosen't work in this code, I want to show a list of customers with a specific data for each customer. The issue is when I want to add a new customer through ...
munsef khasawneh's user avatar
0 votes
1 answer
32 views

Is there any chance to see updated state before function flow is not finished in React for debugging purpose. function a = () => { ....statements setState(a); ....statements {here can I ...
zanhtet's user avatar
  • 2,049
1 vote
1 answer
47 views

have a mistake in a articles.js articles.js: import React, {Component} from 'react'; import './index.css'; export default class Class extends Component { constructor(props) { super(props)...
артур хасанов's user avatar
0 votes
1 answer
104 views

I am currently building a GridView for an image gallery in Flutter, utilizing a provider to manage my media list and to integrate a caching system. The GridView is designed to work with pagination, ...
Spencer's user avatar
  • 135
0 votes
0 answers
82 views

I have a custom chart with clickable points. After a point is clicked I want to change another component which shows that days commits to show the date of the point being clicked. In the parent ...
Doruk's user avatar
  • 233
0 votes
0 answers
34 views

Sometimes I want a parent element to keep track of the children's state. For example, a state that's a list where each item corresponds to exactly one DOM-child. In my application this is a multi-...
Herbert's user avatar
  • 5,695
-1 votes
1 answer
37 views

I am having an issue where everything inside my useEffect call does not seem to be getting updated state variables. Before updating my state variable bboHistory with setBBOHistory, I print prev and I ...
awdreg's user avatar
  • 41
-1 votes
2 answers
43 views

one thing you have to keep in mind. i have create this class in external file and executing sheet from main code because same sheet needed in many of screens. so for showing sheet perfectly first i ...
yogeshdinodia's user avatar
0 votes
1 answer
70 views

I am creating a whatsapp clone. For showing profile picture, I have made a card component which is accessed from a top_bar component. function Show_dp(prop){ return( <div id="box&...
Abhrajit Saha's user avatar
1 vote
2 answers
80 views

const [lap, setLap] = useState([]); function start(){ if(!isStart){ starting = Date.now() - elapsed; isStart = true; timer = setInterval(update, 1000); ...
Abhrajit Saha's user avatar
-1 votes
1 answer
41 views

I changed a state with setState, but it did not trigger a re-render. I considered it a minor issue, so I searched extensively, but I couldn't find a solution. I want to check the second and third ...
yushin's user avatar
  • 1
0 votes
0 answers
52 views

I have the following class: export default class Global { public config!: Config; public components!: Component[]; constructor(config: Config) { if (!config) { throw new Error("...
Ethan's user avatar
  • 1,868
0 votes
1 answer
34 views

I have a app.jsx, which will request two different api named API_A & API_B. I will get data_A and data_B from this two api and merge them into a info state for render ui. My code is like this: ...
chenglili's user avatar
0 votes
1 answer
49 views

I am building the BMI calculator app, after all, it giving me "setState() or markNeedsBuild() called during build." error. so, i come up with below solution.. onTap: () { ...
Alpesh Jasani's user avatar
2 votes
3 answers
298 views

I'm using ReactSearchAutocomplete to display a list of 10 suggested names from a mySql query. The query is performed with a 100ms delay on user input, and it works fine but I'm clearly not handling ...
Dportology's user avatar
1 vote
1 answer
498 views

So here's my issue, im currently learning about the useReducer function and trying to utilize it to create a react based quiz, selection screen. I wanted to update the state (so it could be uplifted ...
user avatar
1 vote
1 answer
59 views

I have a Tabs component that has bunch of NavLinks. I'm trying to show a loading spinner based on the NavLink's isPending property on the parent component. So I'm showing spinner when there is a ...
cyclonejet's user avatar
0 votes
2 answers
53 views

I'm trying to get the totalValue in the title of the appBar. The value of totalValue comes from the Streambuilder and it changes everytime I press the FilterChips. Code: import 'package:flutter/...
Jaime Albornoz Soto's user avatar
0 votes
1 answer
42 views

I have a function that calls 2 functions, one uploads an image and stores it in some directory, and the other send product related data to edit/store in the database: const uploadImage = async () =&...
johnny shepherd's user avatar
0 votes
1 answer
54 views

I have followed the examples on disabling the flutter elevatedbutton after first press, but its not fast enough. Part of my onPressed makes a call to a backend server for data, but its somewhat of a ...
Tom's user avatar
  • 427
0 votes
1 answer
379 views

I'm trying out some very basic way of tracking the Excalidraw (0.17.5) elements in React, but I'm getting something like stack overflow. Why??? import { useState } from "react" import { ...
psygo's user avatar
  • 7,873
0 votes
1 answer
71 views

I have 2 <input type="text"> elements. What users type in input 1 will be the default value of input 2. The value of input 2 will be used for other tasks. The tasks should run right ...
Ooker's user avatar
  • 3,404
-1 votes
1 answer
66 views

Started a course on ReactJS and on Chapter 4 I encountered this issue. I have verified with several posts and none work. setState() is any implementation has not re rendered the component. const ...
Jas Bojan's user avatar
0 votes
1 answer
55 views

I have this Dropdown Widget in a Modal and I cannot Change the Value in the Widget while I'm using setState and everytime I change the value, I should close the Modal and then the Value is Changed. ...
Shervin.bdn's user avatar
0 votes
0 answers
260 views

I am trying to make a simple social media app and I am using a alert dialog for the user to add a new post. Im trying to update the alert dialog using statefulBuilder when I add an image but the image ...
The Synergist's user avatar
-1 votes
1 answer
34 views

Here's my code: import "./styles.css"; import { useState } from "react"; export default function App() { const [input, setInput] = useState("") const [list, setList] =...
Chase's user avatar
  • 1
0 votes
1 answer
61 views

This is my home screen and it is working fine but it is throwing error each time I navigate to it. I don't know what to do , all of the app is working normally , it is just throwing this errors and I ...
MehdiDx's user avatar
  • 25
0 votes
2 answers
78 views

I have a an app-wide file that has several functions that are used several places in the application. In one of those functions I want to call setState. This causes an issue because the function is ...
Kaegan Clark's user avatar
0 votes
2 answers
77 views

I uploaded 3 pages of related code here. My problem is this: I press the Pick Country button and select a country, but I can't display my screen the phoneCode parameter of the country I selected. I'm ...
OGY's user avatar
  • 31
0 votes
1 answer
44 views

The fetch statement getting json data from the server. I want to get the value of the object to be saved in state. The response is only one element in it [{"QuestId":1700}]. How to get the ...
Hasan Zubairi's user avatar
3 votes
1 answer
1k views

Context I am encountering an issue with FutureBuilder in Flutter where it recreates its Future on every widget rebuild, causing unexpected behavior in my app. Specifically, I have a FutureBuilder that ...
MendelG's user avatar
  • 20.6k
0 votes
1 answer
428 views

I want to know what's the best approach to get the current state value. I figured out 2 options to reach the current value instead of getting stale value by whether using useEffect hook or using the ...
maghraby's user avatar
2 votes
2 answers
550 views

Above the first Page that shows, I show a message that the user can swipe left to go to the next page. In onPageChanged I set a bool to dismiss the message and call setState. When I swipe to page 1, ...
Harmen's user avatar
  • 1,022
6 votes
2 answers
2k views

I want to use the SearchAnchor Widget, but unfortunately, I find no way to trigger a rebuild. I have tried many approaches to achieve something similar to what is shown in my picture checklist inside ...
Luca Köster's user avatar
4 votes
2 answers
359 views

I have the following frontend: AuthContext.js: const { createContext, useState, useContext } = require("react"); const AuthContext = createContext(); export function useAuth() { return ...
milanHrabos's user avatar
  • 2,017
-2 votes
1 answer
90 views

Please note - this is NOT a generic Javascript question about async/await vs. .then. If you are curious about that, please look here: Difference of using async / await vs promises?. This is a ...
Octo Palm Tree's user avatar
0 votes
0 answers
30 views

Im trying to set set an IP address into "" and (last queried value). But its always render same state and render new state after second render. I know its because of setState syncronomous ...
splmdny's user avatar
  • 73
0 votes
1 answer
37 views

I have a const in ReactJS which is an object and I want to loops over it to set all values to undefined to reset the state and re-render the component to get a clean form const [newPayee, setNewPayee] ...
Michael Harvey's user avatar
1 vote
2 answers
324 views

I have called setState() to update the objects of the class MyErrorBox, but Flutter does not run the build function for those objects. I am new to Flutter and coding in general. The MyText class in ...
INeedHelp1234's user avatar
-1 votes
1 answer
57 views

I have an array of files that will be uploading, but I want to change the array of file strings to an array of objects which is working fine. But when I try to update the variable to the new array, it ...
Vince's user avatar
  • 2,666

1
2 3 4 5
54