Alert Uygulaması

Alert Uygulaması

import React from 'react';
import { Text, SafeAreaView, StyleSheet } from 'react-native';

// or any files within the Snack
import AssetExample from './components/AssetExample';

function Alert() {
  alert('Selam millet');
}

export default function App() {
  return (
    <SafeAreaView style={styles.container}>
      <Text style={styles.paragraph} onPress={() => {Alert();/*alert('Left button pressed')*/}}>
        Buraya tıklayın
      </Text>
    </SafeAreaView>
  );
}

const styles = StyleSheet.create({
  container: {
    flex: 1,
    justifyContent: 'center',
    backgroundColor: '#ecf0f1',
    padding: 8,
  },
  paragraph: {
    margin: 24,
    fontSize: 18,
    fontWeight: 'bold',
    textAlign: 'center',
  },
});

 

 

Yorumunuzu Ekleyin
Yükleniyor...