Skip to content

RussianBooHackers/BooHackersApp

Repository files navigation

boohack

commit from BARSLONA bar SPB

instruction:

flutter packages get

flutter pub run build_runner build --delete-conflicting-outputs

flutter run

Before first running

add files:

  • android/app/google-services.json
  • android/app/key.jks
  • android/boohackapp.properties
  • android/key.properties

google-services.json

we can download this file in the firebase console. Needed for firebase to work

key.jks

application signature. Google it!

boohackapp.properties

paste this to file and YOUR_MAP_KEY to your map token from google console:

mapKey=<YOUR_MAP_KEY>

key.properties

properties for signature. If it’s not clear what to shove, google it

storePassword=YOUR_STORE_PASSWORD

keyPassword=YOUR_KEY_PASSWORD

keyAlias=YOUR_KEY_ALIAS

storeFile=./key.jks

After adding the files, open the android folder in Android Studio and "build gradle"

If you didn’t succeed in starting the application after my explanations, have a drink and start reading readme first

!!Important note

Since it was added source generation. please run $ flutter pub run build_runner build --delete-conflicting-outputs first or $ flutter pub run build_runner watch --delete-conflicting-outputs for continuous rebuilding. but be aware it can lock the flutter.

To generate docs use

dartdoc

Models

https://charafau.github.io/json2builtvalue/

You can generate base model class using this site. Just paste class from generated code on this site to your model class. Then, remove jsonTo and Json from. Model need to be look like

import 'dart:convert';

import 'package:built_collection/built_collection.dart';
import 'package:built_value/built_value.dart';
import 'package:built_value/serializer.dart';
import 'package:google_maps_flutter/google_maps_flutter.dart';

import 'serializers.dart';

part 'location.g.dart';

abstract class Location implements Built<Location, LocationBuilder> {
  Location._();

  factory Location([updates(LocationBuilder b)]) = _$Location;

  @nullable
  @BuiltValueField(wireName: 'type')
  String get type;
  
  @nullable
  @BuiltValueField(wireName: 'coordinates')
  LatLng get coordinates;

  static Serializer<Location> get serializer => _$locationSerializer;
}

I18n

Examples:

Simple string

/i18n/en-US.json

{
    "title": "Itis template"
}

/lib/screen.dart

I18n.of(context).title // => Itis template

String with parameter

/i18n/en-US.json

{
    "greetTo": "Hello, {name}"
}

/lib/screen.dart

I18n.of(context).greetTo("User name") // => Hello, User name

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published