Skip to content

Instantly share code, notes, and snippets.

@Wizpna
Last active Aug 30, 2021
Embed
What would you like to do?
How I Built a Photo Editing App with 80 lines of code using Flutter and IMG.LY
import 'package:flutter/material.dart';
import 'package:image_picker/image_picker.dart';
import 'package:imgly_sdk/imgly_sdk.dart';
import 'package:photo_editor_sdk/photo_editor_sdk.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatefulWidget {
@override
_MyAppState createState() => _MyAppState();
}
class _MyAppState extends State<MyApp> {
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
title: const Text('PhotoEditor SDK Example'),
centerTitle: true,
),
body: GestureDetector(
onTap: ()=> imgFromGallery(),
child: Center(
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [Text("Click to open photo editor"), Icon(Icons.edit)],
),
),
),
),
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment