17 lines
453 B
Dart
17 lines
453 B
Dart
|
|
|
|
// Automatic FlutterFlow imports
|
|
|
|
import 'index.dart'; // Imports other custom actions
|
|
import 'package:flutter/material.dart';
|
|
import 'dart:convert';
|
|
import 'dart:typed_data';
|
|
import '../../flutter_flow/uploaded_file.dart';
|
|
|
|
Future<String?> convertImageFileToBase64(FFUploadedFile imageFile) async {
|
|
List<int>? imageBytes = imageFile.bytes;
|
|
if (imageBytes != null) {
|
|
String base64Image = base64Encode(imageBytes);
|
|
return base64Image;
|
|
}
|
|
} |