Skip to content

Instantly share code, notes, and snippets.

View austinevick's full-sized avatar
🎯
Focusing

Augustine Victor austinevick

🎯
Focusing
View GitHub Profile
@vganin
vganin / FlexRow.kt
Last active September 1, 2024 19:19
[DEPRECATED, use official FlowRow instead] Jetpack Compose simple flex-wrap container
@Composable
fun FlowRow(
horizontalGap: Dp = 0.dp,
verticalGap: Dp = 0.dp,
alignment: Alignment.Horizontal = Alignment.Start,
content: @Composable () -> Unit,
) = Layout(content = content) { measurables, constraints ->
val horizontalGapPx = horizontalGap.toPx().roundToInt()
val verticalGapPx = verticalGap.toPx().roundToInt()
@kenshinman
kenshinman / Nigerian Mobile Phone Numbers Regex
Created June 3, 2020 12:59
Regex for all Nigerian GSM phone numbers including +234 prefix, and 234 prefix
/^(\+234|234|0)(701|702|703|704|705|706|707|708|709|802|803|804|805|806|807|808|809|810|811|812|813|814|815|816|817|818|819|909|908|901|902|903|904|905|906|907)([0-9]{7})$/
2347031546361 //valid
+2347031546361 //valid
07031546361 //valid
7031546361 //invalid
@felangel
felangel / main.dart
Last active September 13, 2021 21:33
[flutter_bloc_recipes] Show SnackBar
import 'package:flutter/material.dart';
import 'package:bloc/bloc.dart';
import 'package:flutter_bloc/flutter_bloc.dart';
import 'package:meta/meta.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {