verify connection ๐Ÿ’ป๐Ÿ“ถ

check if your device is connected to the internet
// Automatic FlutterFlow imports
import '/flutter_flow/flutter_flow_theme.dart';
import '/flutter_flow/flutter_flow_util.dart';
import '/custom_code/actions/index.dart'; // Imports other custom actions
import '/flutter_flow/custom_functions.dart'; // Imports custom functions
import 'package:flutter/material.dart';
// Begin custom action code
// DO NOT REMOVE OR MODIFY THE CODE ABOVE!

import 'package:internet_connection_checker/internet_connection_checker.dart';

Future<bool> mensaje() async {
  final bool validarConexion = await InternetConnectionChecker().hasConnection;

  return validarConexion;
}

// Set your action name, define your arguments and return parameter,
// and then add the boilerplate code using the button on the right!
2
1 reply