Skip to content

Instantly share code, notes, and snippets.

Avatar
🙊
Apes Together Strong

Agon Noga noga-dev

🙊
Apes Together Strong
View GitHub Profile
@noga-dev
noga-dev / blockman.dart
Created Nov 9, 2021
test code for blockman
View blockman.dart
// Want to support my work 🤝? https://buymeacoffee.com/vandad
import 'package:flutter/material.dart';
class ListItem {
const ListItem();
factory ListItem.emptyTile() => EmptyTile();
factory ListItem.tile(
String title,
String subTitle,
@noga-dev
noga-dev / commitCount.dart
Last active Jun 29, 2021 — forked from codsane/commitCount.py
Simplest way to get commit count of a GitHub repo using the API
View commitCount.dart
import 'dart:html';
void main() async {
print(await getCommits(repo: 'river_pod', owner: 'rrousselGit'));
}
Future<String> getCommits({required String repo, required String owner}) async => RegExp(r'(\d+)')
.allMatches((await HttpRequest.request(
'https://api.github.com/repos/$owner/$repo/commits?per_page=1'))
.responseHeaders['link']!)
@noga-dev
noga-dev / main.dart
Last active Jun 13, 2021
Container vs. SizedBox vs. DecoratedBox
View main.dart
import 'package:flutter/foundation.dart' show kIsWeb;
import 'package:flutter/material.dart';
import 'package:statsfl/statsfl.dart';
void main() {
runApp(
StatsFl(
isEnabled: true,
showText: true,
sampleTime: 0.05,
View gist:23e5ac2c416322c17f7db2fcd2c04137
I/flutter ( 7824): JitsiMeetingOptions: JitsiMeetingOptions{room: plugintestroom, serverURL: https://meet.jitsi.si, subject: My Plugin Test Meeting, token: null, audioMuted: true, audioOnly: true, videoMuted: true, userDisplayName: Plugin Test User, userEmail: fake@email.com}
D/JITSI_MEET_PLUGIN( 7824): method: joinMeeting
D/JITSI_MEET_PLUGIN( 7824): arguments: {videoMuted=true, subject=My Plugin Test Meeting, serverURL=https://meet.jitsi.si, audioOnly=true, audioMuted=true, userDisplayName=Plugin Test User, userEmail=fake@email.com, room=plugintestroom, token=null}
D/JITSI_MEET_PLUGIN( 7824): Joining Room: plugintestroom
W/ActivityThread( 7824): handleWindowVisibility: no activity for token android.os.BinderProxy@1763f06
D/ReactNative( 7824): ReactInstanceManager.createReactContextInBackground()
D/ReactNative( 7824): ReactInstanceManager.attachRootViewToInstance()
I/JitsiMeetSDK( 7824): AudioMode Update audio route for mode: 0
I/JitsiMeetSDK( 7824): AudioMode Updating audio device list
I/JitsiMeetSDK( 7824):
@noga-dev
noga-dev / main.dart
Created Mar 21, 2020
CupertinoPicker example
View main.dart
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
void main() => runApp(
MaterialApp(
debugShowCheckedModeBanner: false,
home: CupPickerDemo(),
),
);
View main.dart
import 'package:flutter/material.dart';
final text = '''
Call me Ishmael. Some years ago—never mind how long precisely—having
little or no money in my purse, and nothing particular to interest me
on shore, I thought I would sail about a little and see the watery part
of the world. It is a way I have of driving off the spleen and
regulating the circulation. Whenever I find myself growing grim about
the mouth; whenever it is a damp, drizzly November in my soul; whenever
I find myself involuntarily pausing before coffin warehouses, and
View main.dart
import 'package:flutter/material.dart';
TextStyle posRes = TextStyle(color: Colors.white, backgroundColor: Colors.red),
negRes = TextStyle(color: Colors.black, backgroundColor: Colors.white);
String search;
final text = '''
Call me Ishmael. Some years ago—never mind how long precisely—having
little or no money in my purse, and nothing particular to interest me
View main.dart
void main() => runApp(
StatefulBuilder(builder: (context, setState) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
backgroundColor: Colors.white,
title: TextField(
style: TextStyle(fontSize: 22),
decoration: InputDecoration(hintText: "Search"),
onChanged: (t) {
View gist:4630740
Before:
<local:Welcome x:Name="WelcomeUserControl" HorizontalAlignment="Center" VerticalAlignment="Center" ImportButtonClick="WelcomeUserControl_ImportButtonClick" NewButtonClick="WelcomeUserControl_NewButtonClick" OpenButtonClick="WelcomeUserControl_OpenButtonClick" OpenRecentFileButtonClick="WelcomeUserControl_OpenRecentFileButtonClick"/>
After:
<local:Welcome
x:Name="WelcomeUserControl"
HorizontalAlignment="Center"