I hereby claim:
- I am kevinresol on github.
- I am kevinresol (https://keybase.io/kevinresol) on keybase.
- I have a public key whose fingerprint is 0411 D430 43CF E70E A1EB A7E1 43D5 3282 049D FB30
To claim this, I am signing this object:
import haxe.Timer; | |
import tink.state.Observable; | |
import coconut.ui.View; | |
import coconut.ui.RenderResult; | |
import coconut.ui.Renderer; | |
import tink.pure.List; | |
using tink.CoreApi; |
function send(message) { | |
var input = document.querySelector('div.pluggable-input-body.copyable-text.selectable-text'); | |
input.innerText = message; | |
input.dispatchEvent(new InputEvent('input', { | |
inputType: 'insertText', | |
data: message, | |
bubbles: true, | |
cancelable: false, | |
composed: true, | |
detail: 0, |
package api; | |
// to use: add `implements api.Wiper` to your API class | |
// but it doesn't handle imports, either you use wildcard (import api.*) or guard them with `#if` | |
#if macro | |
import haxe.macro.Context; | |
using tink.MacroApi; | |
#end |
I hereby claim:
To claim this, I am signing this object:
# Posts | |
## Categories | |
| Name | Slug | | |
| -- | -- | | |
| Contact | contact | | |
| Home Banner | home-banner | | |
| Home Masthead | home-masthead | | |
| Work | work | |
class Map extends View<{workers:WorkersData}> { | |
var map:GoogleMap; | |
var markers:Array<GoogleMapMarker> = []; | |
var locations:List<Location>; | |
function render() { | |
// "extract" the location and store in class variable | |
// this also cause render() to run again when the `locations` are updated | |
this.locations = workers.locations; |
lix install haxelib:travix | |
lix install haxelib:hxnodejs | |
lix install gh:haxetink/tink_chunk | |
lix install gh:haxetink/tink_streams#pure | |
lix install gh:haxetink/tink_io#pure | |
lix install gh:haxetink/tink_http#pure | |
lix install gh:haxetink/tink_web#pure | |
class Pool<T> { | |
var pool:Array<T>; | |
var factory:Void->T; | |
public function new(factory) { | |
this.factory = factory; | |
pool = []; | |
} | |
public function get() { | |
if(pool.length == 0) return factory(); | |
return pool.pop(); |
Copy expressions with Haxe macro |
Convert js-style callback to Future, with macro |