Posts by Nycollas • 69 points
9 posts
-
3
votes1
answer213
viewsA: How to toggle the status of only one item in Flatlist?
I managed to solve, just create a separate component and call this component in the render of the flatlist by passing the props Flatlist: const Sounds: React.FC = () => { return (…
-
1
votes1
answer213
viewsQ: How to toggle the status of only one item in Flatlist?
I have the following code: const Sounds: React.FC = () => { const [hasSelect, setHasSelect] = useState(false); return ( <Container> <FlatList data={data} keyExtractor={item =>…
-
0
votes2
answers335
viewsA: Validate fields in React
You can do a check before browsing, if all states are different from an empty string, then you can browse. const [ name, setName ] = useState(''); const [ user, setUser ] = useState(''); const […
-
0
votes0
answers14
viewsQ: Audio Expo does not pause the music
The sound plays normally, but the pause doesn’t work. I tried several algorithms and nothing worked. I think it’s something with the Promisses, because I don’t know much about asynchrony. But when I…
-
0
votes1
answer62
viewsQ: Image does not render
I’m taking any image in a folder at the root of the project and the image doesn’t render... There’s that image icon with the alt. I’ve looked at several topics and sites, I do everything exactly the…
-
0
votes1
answer173
viewsQ: useEffect does not recognize new value
The useEffect hook fires when some variable in your array refreshes. However, when the value of the variable remains the same, the hook simply ignores. This hook gets a value and a push on the array…
-
0
votes2
answers444
viewsA: How to authenticate user using your Google account in an app built with Expo (React Native)?
Look friend, the Expo is very limited in production, I recommend you use React Native CLI for complex projects like this one of yours. Maybe the expo team doesn’t have a module or a solution for…
-
-1
votes1
answer612
viewsQ: Typeerror: Undefined is not an Object (evaluating 'this.sound.playAsync')
I can’t handle very well with The Expo-av (I don’t think anyone knows why I can’t find tutorials), but what I’m doing wrong? Error import React,{ Component } from 'react'; import { View,…
-
1
votes0
answers45
viewsQ: How to go down with an object on the canvas
I’m creating a 1970 game design similar to this: When I ask the canvas to draw the ball down, instead it continues a line like this: Follows the code: ball = { xStart: 190, xEnd: 15, yStart: 200,…