Can't pass value as function in React Navite Element Button

I want to display model with the key value from array, but I can't do it, and I don't understand the problem.

I want to display model with the key value from array, but I can't do it, and I don't understand the problem.

this is react native in Expo and I have used react native elements

import React, {Component} from "react";
import { ScrollView, Text, Linking, View, Modal } from "react-native";
import { Card, Button } from "react-native-elements";
import PriceDetail from "./PriceDetail";

const images = [
{
key: 1,
name: "Nathan Anderson",
image: require("../images/1.jpg"),
url: "https://unsplash.com/photos/C9t94JC4_L8"
},
{
key: 2,
name: "Jamison McAndie",
image: require("../images/2.jpg"),
url: "https://unsplash.com/photos/waZEHLRP98s"
},
{
key: 3,
name: "Alberto Restifo",
image: require("../images/3.jpg"),
url: "https://unsplash.com/photos/cFplR9ZGnAk"
},
{
key: 4,
name: "John Towner",
image: require("../images/4.jpg"),
url: "https://unsplash.com/photos/89PFnHKg8HE"
}
];

class Home extends Component {

state = {
selectedItem : null,
mvisible : false
}

modalClosedHandler = () => {
this.setState({
mvisible: false,
selectedItem: null
});
};

productSelectedHandler = key => {
this.setState(prevState => {
return {
selectedItem: prevState.images.find(image => {
return image.key === key;
})
};
});
console.log(selectedItem);
};

showModal = (key) => {
this.setState({
mvisible: true,
selectedItem: key
});
}

render () {
return (
<View style={{ flex: 1 }}>
<Modal
visible={this.state.mvisible}
onRequestClose={this.modalClosedHandler}>
<View style={{flex : 1, alignItems: 'center', justifyContent: 'center'}}>
<Text>Hello this is modal{this.state.selectedItem}</Text>
<Button title="Close" onPress={this.modalClosedHandler}/>
</View>
</Modal>
<ScrollView contentContainerStyle={{ paddingVertical: 20 }}>
{images.map(({ name, image, url, key }) => (
<Card title={Product ${key}} image={image} key={key}>
<Text style={{ marginBottom: 10 }}>
Photo by {name}.
</Text>
<Button
backgroundColor="#03A9F4"
title="VIEW NOW"
onPress={(key)=>this.showModal(key)}
/>
</Card>
))}
</ScrollView>
</View>
);
}
}

export default Home;


Angular 9 Tutorial: Learn to Build a CRUD Angular App Quickly

What's new in Bootstrap 5 and when Bootstrap 5 release date?

What’s new in HTML6

How to Build Progressive Web Apps (PWA) using Angular 9

What is new features in Javascript ES2020 ECMAScript 2020

How to Share Code Between React and React Native

How to Share Code Between React and React Native

Learn how to share code between React and React Native to avoid duplicating logic. Sharing Code Between React and React-Native: What Not to Share. This question of sharing code between React and React Native, in fact, one of the hot topics among React and React native developers all over the world. React and React-Native allow a learn once write anywhere paradigm. This is great, because one tech team can build both your web app and native mobile experience. The problem is developers hate writing things twice. There have been a couple of efforts to build a unifying technology to write an application once and have it work on both web and native.

How to Share Code Between React and React Native

Sharing Code Between React and React-Native: What Not to Share - Ben Ellerby

React and React-Native allow a learn once write anywhere paradigm. This is great, because one tech team can build both your web app and native mobile experience. The problem is developers hate writing things twice. There have been a couple of efforts to build a unifying technology to write an application once and have it work on both web and native. Yet this is not always the best approach. There is value in only sharing your business and state logic; keeping your render code separate.

In this talk I will give real examples from my work with MADE.COM, migrating their web and mobile application to React and React-Native with code sharing as a primary objective.

How to Share Code Between React and React Native

Learn how to share code between React and React Native to avoid duplicating logic

Sharing Code Between React and React Native

React and React-Native allow a learn once write anywhere paradigm. This is great, because one tech team can build both your web app and native mobile experience. The problem is developers hate writing things twice. There have been a couple of efforts to build a unifying technology to write an application once and have it work on both web and native. Yet this is not always the best approach. There is value in only sharing your business and state logic; keeping your render code separate.

React Native vs Flutter | Difference Between React Native & Flutter

React Native vs Flutter | Difference Between React Native & Flutter

This video on React Interview Questions will help you crack your next React interview with ease. React is the most popular front-end JavaScript library today and is being adopted by many big companies like Netflix, Airbnb, New York Times, and many more...

This video on React Interview Questions will help you crack your next React interview with ease. React is the most popular front-end JavaScript library today and is being adopted by many big companies like Netflix, Airbnb, New York Times, and many more. It is also used in small projects by web developers to showcase their skills in the field of web development. The video includes general React interview questions as well as questions focused on Redux, Hooks, and Styling. This video is ideal for both beginners as well as experienced professionals who are appearing for React web development job interviews. Learn the most important React interview questions and answers and know what will set you apart in the interview process.

React Native Tutorial : Build Dota 2 fan app in React Native

React Native Tutorial : Build Dota 2 fan app in React Native

In this video I'll talk about my approach on how I built a react native app, that I've been working on as a side project for ~1 week, for ios and android and what it can do.

In this video I'll talk about my approach on how I built a react native app, that I've been working on as a side project for ~1 week, for ios and android and what it can do.

The idea for the app was basically to help dota fans quickly browse vods of ongoing/previous tournaments, check upcoming matches, read news and play a little prediction mini game.

In the video I explain why I decided not to publish it.

I used a bunch of web scraping(cheerio) from my node backend to get the content needed for the app and a mongo database to store the data.