“Efek flash di React Native” Kode Jawaban

Efek flash di React Native

showMessage({
  message: "My message title",
  description: "My message description",
  type: "default",
  backgroundColor: "purple", // background color
  color: "#606060", // text color
});
Helpless Hippopotamus

Efek flash di React Native

import React from "react";
import { View, Button } from "react-native";

import { showMessage, hideMessage } from "react-native-flash-message";

class MyScreen extends React.Component {
  render() {
    return (
      <View style={{ flex: 1 }}>
        <Button
          onPress={() => {
            /* HERE WE GONE SHOW OUR FIRST MESSAGE */
            showMessage({
              message: "Simple message",
              type: "info",
            });
          }}
          title="Request Details"
          color="#841584"
        />
      </View>
    );
  }
}
Helpless Hippopotamus

Efek flash di React Native

showMessage({
  message: "My message title",
  description: "My message description",
  type: "success",
  onPress: () => {
    /* THIS FUNC/CB WILL BE CALLED AFTER MESSAGE PRESS */
  },
});
Helpless Hippopotamus

Jawaban yang mirip dengan “Efek flash di React Native”

Pertanyaan yang mirip dengan “Efek flash di React Native”

Lebih banyak jawaban terkait untuk “Efek flash di React Native” di JavaScript

Jelajahi jawaban kode populer menurut bahasa

Jelajahi bahasa kode lainnya