Skip to content

Instantly share code, notes, and snippets.


Reme Le Hane RemeJuan

View GitHub Profile
RemeJuan / .zshrc
Created Jun 16, 2021
oh-my-zsh config
View .zshrc
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH="/Users/remelehane/.oh-my-zsh"
# Set name of the theme to load --- if set to "random", it will
# load a random theme each time oh-my-zsh is loaded, in which case,
# to know which specific one was loaded, run: echo $RANDOM_THEME
# See
RemeJuan / html_utils_test.dart
Created Mar 31, 2021
Unit Testing a Utility function that returns a Widget (Test)
View html_utils_test.dart
testWidgets('cant', (tester) async {
when( async => false);
// assert
const mockUrl = 'https://test.test';
Future<void> future(BuildContext context) async {
await Future.delayed(const Duration(seconds: 1));
return htmlContentUtils.launchURL(context, mockUrl);
RemeJuan / html_utils.dart
Last active Jun 12, 2021
Unit Testing a Utility function that returns a Widget (Code)
View html_utils.dart
dynamic launchURL(BuildContext context, String url) async {
if (url == 'about:blank') return;
if (url.startsWith('internal://')) {
final isGroups = url.contains('/groups');
if (isGroups) return _handleUnsupported(context);
RemeJuan / completer_hook.dart
Created Jul 8, 2020
Flutter hook for Completer (dart:async)
View completer_hook.dart
import 'dart:async';
import 'package:flutter/src/widgets/framework.dart';
import 'package:flutter_hooks/flutter_hooks.dart';
class _CompleterHook extends Hook<Completer> {
HookState<Completer, Hook<Completer>> createState() => _CompleterHookState();
RemeJuan / azure.yaml
Last active Apr 27, 2020
Flutter pipeline config
View azure.yaml
name: Azure Pipelines
demands: xcode
- script: 'brew install fastlane'
displayName: 'Install fastlane'
- script: |
gem install bundler
RemeJuan / api.dart
Created Jul 6, 2019
View api.dart
import 'dart:io';
import 'dart:convert';
import 'package:cookie_jar/cookie_jar.dart';
var cj = new CookieJar();
class Session {
static HttpClient client = new HttpClient()
View blocks.txt
RemeJuan / action.js
Created May 21, 2018
Race Conditions Redux
View action.js
export const searchPostNoResults = data => ({
RemeJuan / cloudSettings
Last active Dec 15, 2020
Visual Studio Code Settings Sync Gist
View cloudSettings
const SWPrecacheWebpackPlugin = require('sw-precache-webpack-plugin');
const WebpackPwaManifest = require('webpack-pwa-manifest');
const PUBLIC_PATH = '';
module: {
// Snip
plugins: [
// Snip
new SWPrecacheWebpackPlugin(