GithubHelp home page GithubHelp logo

amudamai / flutter-firebase-masterclass Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bizz84/flutter-firebase-masterclass

0.0 0.0 0.0 2.9 MB

Flutter & Firebase Masterclass

Home Page: https://codewithandrea.com/courses/flutter-firebase-masterclass/

License: MIT License

JavaScript 0.22% Ruby 1.07% C++ 5.59% C 0.34% Objective-C 0.01% Kotlin 0.03% Dart 83.42% TypeScript 3.93% Swift 0.44% HTML 0.44% CMake 4.50%

flutter-firebase-masterclass's Introduction

Flutter & Firebase Masterclass - eCommerce App

This is the official repo for this course:

Inside, we will build a full-stack eCommerce app using Flutter & Firebase:

eCommerce App Preview

To try it out, head over here:

Project Setup

To clone the repo for the first time and open it in VSCode, run this:

git clone https://github.com/bizz84/flutter-firebase-masterclass.git
cd flutter-firebase-masterclass
code .

This will checkout the main branch which contains the latest code.

But at various points in the course, I'll ask you to checkout a specific branch name, so you can follow along with the right code, at the right time.

And to prevent any conflicts, you may need to reset your local changes:

git reset --hard HEAD
git checkout <branch-name>

Firebase Setup

Since the project uses Firebase, some additional files will be needed:

lib/firebase_options.dart
ios/Runner/GoogleService-Info.plist
ios/firebase_app_id_file.json
macos/Runner/GoogleService-Info.plist
macos/firebase_app_id_file.json
android/app/google-services.json

These files have been added to .gitignore, so you need to run this command to generate them with the flutterfire CLI:

cd ecommerce_app
flutterfire configure

Stripe Setup

In module 8 of the course, we add Stripe to the eCommerce app.

For the Stripe code to work, a STRIPE_PUBLISHABLE_KEY needs to be set on the client.

To set it, create an .env file inside the ecommerce_app folder and add your Stripe publishable key:

# ecommerce_app/.env
STRIPE_PUBLISHABLE_KEY=pk_test_YOUR_STRIPE_PUBLISHABLE_KEY

Then, run the generator:

dart run build_runner build -d

This will generate an env.g.dart file inside lib.

As a result, the API key can be read as Env.stripePublishableKey in the Stripe setup code.

Note

API keys defined with --dart-define-from-file were failing to load on Flutter web in release mode (see this answer and this comment). To work around that, the project now uses the Envied package.

Documentation site

A documentation site with useful FAQs and guides can be found here:

flutter-firebase-masterclass's People

Contributors

bizz84 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.