وبلاگ بلیان

Flutter Cookbook: 100+ step-by-step recipes for building cross-platform, professional-grade apps with Flutter 3.10.x and Dart 3.x, 2nd Edition

معرفی کتاب «Flutter Cookbook: 100+ step-by-step recipes for building cross-platform, professional-grade apps with Flutter 3.10.x and Dart 3.x, 2nd Edition» نوشتهٔ Simone Alessandria, Brian Kayfitz، منتشرشده توسط نشر Packt Publishing در سال 2023. این کتاب در 5 صفحه، فرمت pdf، زبان انگلیسی ارائه شده است.

Write, test, and publish your web, desktop, and embedded apps with this most up-to-date book on Flutter using the Dart programming language. Key Features Thoroughly updated to cover the latest features in Flutter 3.10.x and Dart 3.x Practical recipes to publish responsive, multi-platform apps from a single database Covers not just the 'hows' but the 'whys' of Flutter's features with examples Book Description Are you ready to tap into the immense potential of Flutter? With over 1,000 new mobile apps published every day on the Apple and Google Play stores, Flutter is transforming the landscape of app development. It's time for you to join the revolution. Introducing the second edition of Flutter Cookbook, a step-by-step guide designed exclusively for you. Whether you're a seasoned developer or just starting your coding journey, this book is your ultimate companion. Dive into the latest features of Flutter 3.10 and unlock the secrets to building professional-grade, cross-platform applications. With our recipe-based approach, we'll not only show you how to implement Flutter's features but also explain why they work. Through practical examples and real-world execution, you'll gain a deeper understanding of Flutter's inner workings. From crafting stunning UI/UX with widgets to leveraging hot reload and restart techniques, we'll equip you with best practices and invaluable knowledge. As you progress, you'll learn to efficiently manage data, add interactivity and animations, and integrate essential Flutter plugins like maps, camera, voice recognition and more. And let's not forget the dedicated chapter on implementing MLkit powered by TensorFlow Lite. We'll guide you through building custom machine learning solutions, expanding the capabilities of your apps. By the time you reach the end of this comprehensive Flutter book, you'll have the skills and confidence to write and deliver fully functional apps. What you will learn Familiarize yourself with Dart fundamentals and set up your development environment Efficiently track and eliminate code errors with proper tools Create various screens using multiple widgets to effectively manage data Craft interactive and responsive apps by incorporating routing, page navigation, and input field text reading Design and implement a reusable architecture suitable for any app Maintain control of your codebase through automated testing and developer tooling Develop engaging animations using the necessary tools Enhance your apps with ML features using Firebase MLKit and TensorFlow Lite Successfully publish your app on the Google Play Store and the Apple App Store Who this book is for Developers who are familiar with the OOP language and prefer learning-by-doing will get the most out of this book. If you have some experience building apps on Flutter or have been playing around with the framework for some time now and have set eyes on developing mobile apps using Dart, then this book is for you. Table of Contents Getting Started with Flutter Creating Your First Flutter App Dart: A Language You Already Know Introduction to Widget Mastering Layout and Taming the Widget Tree Adding Interactivity and Navigation to Your App Basic State Management The Future is Now: Introduction to Asynchronous Programming Data Persistence and Communicating with the Internet Advanced State Management with Streams Using Flutter Packages Adding Animations to Your App Using Firebase Firebase Machine Learning Flutter Web and Desktop Distributing Your Mobile App Cover Copyright Table of Contents Preface Chapter 1: Getting Started with Flutter Why Flutter? Technical requirements Installing Flutter: a high-level overview Installing the Flutter SDK How to use Git to manage the Flutter SDK Installing Git How to do it... Setting up the command line and saving path variables macOS command-line setup Windows command-line setup Linux command-line setup Confirming your environment is correct with Flutter Doctor Configuring the iOS SDK Downloading Xcode CocoaPods Xcode command-line tools Homebrew Checking in with the Doctor Configuring the Android SDK setup Installing Android Studio Creating an Android emulator Which IDE/editor should you choose? Android Studio VS Code IntelliJ IDEA Emacs Picking the right channel Summary Chapter 2: Creating Your First Flutter App How to create a Flutter app How to do it... How to choose a platform language for your app Where do you place your code? Hot reload—refresh your app without recompiling Creating a unit test Getting ready How to do it... How it works... See also Summary Chapter 3: Dart: A Language You Already Know Technical requirements Declaring variables—var versus final versus const Getting ready How to do it... How it works... There’s more... See also Strings and string interpolation Getting ready How to do it... How it works... There’s more... See also How to write functions Getting ready How to do it... How it works... How to use functions as variables with closures Getting ready How to do it... How it works... Using Switch Expressions, Records and Patterns Getting ready How to do it... How it works... There’s more... Creating classes and using the class constructor shorthand Getting ready How to do it... How it works... The building blocks of OOP See also How to group and manipulate data with collections Getting ready How to do it... How it works... Subscript syntax There’s more... See also Writing less code with higher-order functions Getting ready How to do it... How it works... Mapping Sorting Filtering Reducing Flattening There’s more... First-class functions Iterables and chaining higher-order functions See also How to take advantage of the cascade operator Getting ready How to do it... How it works... See also Using extensions Getting ready How to do it... How it works... Introducing Dart Null Safety Getting ready How to do it... How it works... See also Using Null Safety in classes Getting ready How to do it... How it works... See also Summary Chapter 4: Introduction to Widgets Technical requirements Creating immutable widgets How to do it... How it works... Using a Scaffold Getting ready How to do it... How it works... Using the Container widget Getting ready How to do it... How it works... Printing stylish text on the screen Getting ready How to do it... How it works... There’s more... See also Importing fonts and images into your app Getting ready How to do it... How it works... See also Summary Chapter 5: Mastering Layout and Taming the Widget Tree Placing widgets one after another Getting ready How to do it... How it works... Proportional spacing with the Flexible and Expanded widgets Getting ready How to do it... How it works... See also Drawing shapes with CustomPaint Getting ready How to do it... How it works... There’s more... See also Nesting complex widget trees Getting ready How to do it... How it works... See also Refactoring widget trees to improve legibility Getting ready How to do it... How it works... See also Applying global themes Getting ready How to do it... How it works... There’s more... See also Summary Chapter 6: Adding Interactivity and Navigation to Your App Adding state to your app Getting ready How to do it... How it works... There’s more... See also Interacting with buttons Getting ready How to do it... How it works... Making it scroll Getting ready How to do it... How it works... There’s more... Handling large datasets with list builders How to do it... How it works... There’s more... Working with TextFields Getting ready How to do it... How it works... See also Navigating to the next screen How to do it... How it works... Showing dialogs on the screen Getting ready How to do it... How it works... There’s more... Presenting bottom sheets Getting ready How to do it... How it works... See also Summary Chapter 7: Basic State Management Technical requirements Model-view separation Getting ready How to do it... How it works... See also Managing the data layer with InheritedWidget and InheritedNotifier Getting ready How to do it... How it works... See also Making the app state visible across multiple screens Getting ready How to do it... How it works... See also Summary Chapter 8: The Future is Now: Introduction to Asynchronous Programming Technical requirements Using a Future Getting ready How to do it... How it works... See also Using async/await to avoid callbacks Getting ready How to do it... How it works... See also Completing Futures Getting ready How to do it... How it works... There’s more... See also Firing multiple Futures at the same time Getting ready How to do it... How it works... Resolving errors in asynchronous code Getting ready How to do it... Dealing with errors using the then() callback: Dealing with errors using async/await How it works... See also Using Futures with StatefulWidgets Getting ready How to do it... How it works... There’s more... See also Using the FutureBuilder to let Flutter manage your Futures Getting ready How to do it... How it works... There’s more... See also Turning navigation routes into asynchronous functions Getting ready How to do it... How it works... Getting the results from a dialog Getting ready How to do it... How it works... See also Summary Chapter 9: Data Persistence and Communicating with the Internet Technical requirements Converting Dart models into JSON Getting ready How to do it... How it works... Reading the JSON file Transforming the JSON string into a list of Map objects Transforming the Map objects into Pizza objects There’s more... See also Handling JSON schemas that are incompatible with your models Getting ready How to do it... How it works... See also Catching common JSON errors Getting ready How to do it... How it works... See also Saving data simply with SharedPreferences Getting ready How to do it... How it works... See also Accessing the filesystem, part 1: path_provider Getting ready How to do it... How it works... See also Accessing the filesystem, part 2: Working with directories Getting ready How to do it... How it works... See also Using secure storage to store data Getting ready How to do it... How it works... See also Designing an HTTP client and getting data Getting ready How to do it... How it works... There’s more... See also POST-ing data Getting ready How to do it... How it works... PUT-ting data Getting ready How to do it... How it works... DELETE-ing data Getting ready How to do it... How it works... Chapter 10: Advanced State Management with Streams Technical requirements How to use Dart streams Getting ready How to do it... How it works... There’s more... See also Using stream controllers and sinks Getting ready How to do it... How it works... There’s more... See also Injecting data transforms into streams Getting ready How to do it... How it works... See also Subscribing to stream events Getting ready How to do it... How it works... See also Allowing multiple stream subscriptions Getting ready How to do it... How it works... See also Using StreamBuilder to create reactive user interfaces Getting ready How to do it... How it works... See also Using the BLoC pattern Getting ready How to do it... How it works... See also Summary Chapter 11: Using Flutter Packages Technical requirements Importing packages and dependencies Getting ready How to do it... How it works... See also Using dev dependencies Getting ready How to do it... How it works... See also Creating your own package (part 1) Getting ready How to do it... How it works... See also Creating your own package (part 2) Getting ready How to do it... How it works... See also Creating your own package (part 3) Getting ready How to do it... How it works... See also Adding Google Maps to your app Getting ready How to do it... Adding Google Maps on Android Adding Google Maps on iOS How it works... See also Using location services Getting ready How to do it... How it works... See also Adding markers to a map Getting ready How to do it... How it works... There’s more... Summary Chapter 12: Adding Animations to Your App Creating basic container animations Getting ready How to do it... How it works... See also Designing animations part 1 — Using the AnimationController Getting ready How to do it... How it works... See also Designing animations part 2 — Adding multiple animations Getting ready How to do it... How it works... Designing animations part 3 — Using curves Getting ready How to do it... How it works... See also Optimizing animations Getting ready How to do it... How it works... See also Using Hero animations Getting ready How to do it... How it works... See also Using premade animation transitions Getting ready How to do it... How it works... See also Using the AnimatedList widget Getting ready How to do it... How it works... See also Implementing swiping with the Dismissible widget Getting ready How to do it... How it works... See also Using the animations Flutter package Getting ready How to do it... How it works... See also Summary Chapter 13: Using Firebase Configuring a Firebase app Getting ready How to do it... Adding Firebase dependencies How it works... See also Creating a login screen Getting ready How to do it... How it works... See also Adding Google Sign-in Getting ready How to do it... How it works... See also Customizing Sign in Getting ready How to do it... How it works... Integrating Firebase Analytics Getting ready How it works... How it works... See also Using Firebase Cloud Firestore Getting ready How to do it... How it works... See also Sending push notifications with Firebase Cloud Messaging (FCM) Getting ready How to do it... How it works... See also Storing files in the cloud Getting ready How to do it... How it works... Summary Chapter 14: Firebase Machine Learning Using the device’s camera Getting ready How to do it... How it works... See also Recognizing text from an image Getting ready How to do it... How it works... See also Reading a barcode Getting ready How to do it... How it works... See also Image labeling Getting ready How to do it... How it works... Building a face detector and detecting facial gestures Getting ready How to do it... How it works... See also Identifying a language Getting ready How to do it... How it works... See also Using TensorFlow Lite Getting ready How to do it... How it works... See also Summary Chapter 15: Flutter Web and Desktop Creating a responsive app leveraging Flutter Web Getting ready How to do it... How it works... See also... Running your app on macOS Getting ready How to do it... How it works... See also Running your app on Windows Getting ready How to do it... How it works... See also... Deploying a Flutter website Getting ready How to do it... How it works... See also... Responding to mouse events in Flutter Desktop Getting ready How to do it... How it works... See also Interacting with desktop menus Getting ready How to do it... How it works... See also... Summary Chapter 16: Distributing Your Mobile App Technical requirements Registering your iOS app on App Store Connect Getting ready How to do it... How it works... See also Registering your Android app on Google Play Getting ready How to do it... How it works... See also Installing and configuring fastlane Getting ready How to do it... Installing fastlane on Windows Installing fastlane on a Mac Configuring fastlane for Android Installing fastlane for iOS See also Generating iOS code signing certificates and provisioning profiles Getting ready How to do it... How it works... See also Generating Android release certificates Getting ready How to do it... How it works... See also Configuring your app metadata Getting ready How to do it... Adding Android metadata Adding metadata for iOS How it works... See also Adding icons to your app Getting ready How to do it... How it works... See also Publishing a beta version of your app in the Google Play Store Getting ready How to do it... How it works... See also Using TestFlight to publish a beta version of your iOS app Getting ready How to do it... How it works... See also Publishing your app to the stores Getting ready How to do it... Moving your app to production in the Play Store Moving your app to production in the App Store How it works... See also Summary Packt page Other Books You May Enjoy Index Write, test and publish your web, desktop, and embedded apps with this most up-to-date book on Flutter using the Dart programming language. Key Features: Thoroughly updated to cover the latest features in Flutter 3.x and Dart 3 (alpha) Practical recipes to publish responsive, multi-platform apps from a single database Covers not just the 'hows' but the 'whys' of Flutter's features with examples Book Description: Discover how to master Flutter and become a skilled app developer with the Flutter Cookbook, Second Edition! This recipe-based guide is the ultimate solution for creating cutting-edge, high-performance mobile apps that stand out in the market. With the latest features of Flutter 3.x, you'll learn how to set up and customize the Flutter SDK for macOS and Windows, build a robust architecture for your application, and master state management solutions and networking techniques. From mastering widgets and creating effective UI/UX design to implementing hot reload and re-start techniques, this book covers all the aspects of developing a successful app. You'll dive deep into the fundamentals of Dart programming and gain expert knowledge on managing incoming and outgoing data, and adding interactivity, animations, and essential Flutter plugins like maps, camera, voice, and more. Moreover, you'll explore custom machine learning solutions with a dedicated chapter on implementing MLkit, which runs on TensorFlow Lite. By the end of this book, you'll have the confidence to write fully functional Flutter apps that are ready to hit the market. Take your Flutter development skills to the next level with the Flutter Cookbook, Second Edition! What You Will Learn: Familiarize yourself with Dart fundamentals and set up your development environment Efficiently track and eliminate code errors with proper tools Create various screens using multiple widgets to effectively manage data Craft interactive and responsive apps by incorporating routing, page navigation, and input field text reading Design and implement a reusable architecture suitable for any app Maintain control of your codebase through automated testing and developer tooling Develop engaging animations using the necessary tools Enhance your apps with ML features using Firebase MLKit and TensorFlow Lite Who this book is for: This book is aimed at developers who are already familiar with OOP languages and prefer learning through practical applications. If you have prior experience building apps on Flutter or have spent some time experimenting with the framework and are interested in developing mobile apps using Dart, then this book will be highly beneficial for you. Write, test, and publish your web, desktop, and embedded apps with this most up-to-date book on Flutter using the Dart programming language. * Thoroughly updated to cover the latest features in Flutter 3.10.x and Dart 3.x * Practical recipes to publish responsive, multi-platform apps from a single database * Covers not just the 'hows' but the 'whys' of Flutter's features with examples Are you ready to tap into the immense potential of Flutter? Introducing the second edition of Flutter Cookbook, a step-by-step guide designed exclusively for you. Whether you're a seasoned developer or just starting your coding journey, this book is your ultimate companion. Dive into the latest features of Flutter 3.10 and unlock the secrets to building professional-grade, cross-platform applications. As you progress, you'll learn to efficiently manage data, add interactivity and animations, and integrate essential Flutter plugins like maps, camera, voice recognition and more. And let's not forget the dedicated chapter on implementing MLkit powered by TensorFlow Lite. We'll guide you through building custom machine learning solutions, expanding the capabilities of your apps. ## What you will learn ## Who this book is for If you have some experience building apps on Flutter or have been playing around with the framework for some time now and have set eyes on developing mobile apps using Dart, then this book is for you. 1. Getting Started with Flutter 2. Creating Your First Flutter App 3. Dart: A Language You Already Know 4. Introduction to Widget 5. Mastering Layout and Taming the Widget Tree 6. Adding Interactivity and Navigation to Your App 7. Basic State Management 8. The Future is Now: Introduction to Asynchronous Programming 9. Data Persistence and Communicating with the Internet 10. Advanced State Management with Streams 11. Using Flutter Packages 12. Adding Animations to Your App 13. Using Firebase 14. Firebase Machine Learning 15. Flutter Web and Desktop 16. Distributing Your Mobile App
دانلود کتاب Flutter Cookbook: 100+ step-by-step recipes for building cross-platform, professional-grade apps with Flutter 3.10.x and Dart 3.x, 2nd Edition