Skip to content

Instantly share code, notes, and snippets.

View matb33's full-sized avatar

Mathieu Bouchard matb33

View GitHub Profile
App&
Pages
About*
dashboard -> Dashboard
Dashboard
about -> About
Menu
Closed*
toggle -> Opened
Opened
Intro
next -> Terms
Terms
back -> Intro
accepted -> EULA
Accept Dialog 1
Display 1*
accept -> Accepted 1
Accepted 1
# <- accepted
@matb33
matb33 / SketchSystems.spec
Last active June 6, 2019 23:07
Driver Idle
Driver Idle
ping received -> Evaluating Opportunity
Evaluating Opportunity
accept -> On The Way To Merchant
decline -> Driver Idle
On The Way To Merchant
arrived -> Taking Photo
Driver Idle
ping received -> Evaluating Opportunity
Evaluating Opportunity
accept -> On The Way To Merchant
decline -> Driver Idle
On The Way To Merchant
arrived -> Taking Photo
@matb33
matb33 / SketchSystems.spec
Last active June 13, 2019 13:46
# What I'm attempting to highlight here are 3 things in relation to WireState:
# What I'm attempting to highlight here are 3 things in relation to WireState:
# 1. The need for @include (which you've solved!) -- it's impossible to re-use statecharts
# . with SketchSystems
# 2. The need for being able to re-use state names (... solved?) -- again, SketchSystems
# . unique IDs prevent any kind of composability
# 3. A proposal for a new syntax that actually doesn't technically do anything, but would
# . allow us to mimic the `send` style syntax from our imported machines. We both know
# . that in this case, `accept` is already available as an event while in either the
# . "Condensed" or "Expanded" states since the event will bubble up. But it's not obvious
# . if you're looking at the "Display" tree isolated in a separate statechart that will be
Entry
Credentials Flow*
Loading Credentials*
done -> Credentials Available?
error -> What Kind Of Loading Credentials Error?
What Kind Of Loading Credentials Error?
unauthenticated? -> Unauthorizing
any other error? -> Loading Credentials Error
Credentials Available?
yes? -> Account Flow
@matb33
matb33 / facebook.html
Created December 22, 2014 17:21
FacebookCollections help for Eduardo
<head>
<title>facebook</title>
</head>
<body>
<h1>Welcome to Meteor!</h1>
{{> loginButtons}}
{{> posts}}
</body>
@matb33
matb33 / getprimaryip.sh
Created December 13, 2014 14:38
Utility script to get the primary local IP address on your system. Works in Linux and OSX.
#!/bin/bash
if [ "$(which ipconfig)" != "" ]; then
for i in $(ifconfig -ul); do
if [[ $i != lo* ]]; then
ipaddr=$(ipconfig getifaddr $i)
if [ "$ipaddr" != "" ]; then
echo $ipaddr
exit 0
fi
@matb33
matb33 / install-meteor-cordova.sh
Last active August 29, 2015 14:07
Temporary measure to install a different version of Cordova in Meteor
#!/bin/bash
# Make sure to update METEOR_VERSIONS below to point to your app's versions file
TARGET_VERSION=$1
BASEPATH="$(dirname "$0")"
BASEPATH="$(cd "$BASEPATH" && pwd)"
METEOR_VERSIONS=$BASEPATH/../app/.meteor/versions
if [ "$TARGET_VERSION" == "" ]; then
@matb33
matb33 / README.md
Created January 11, 2014 00:31
Reactive async pattern

Example usage:

Template.xyz.value = function () {
  return ReactiveAsync("Template_xyz_value", function (w) {
  	someAsyncFunction(function (result) {
  		w.set(result);
  		w.done();
  	});
 }, {initial: ""});