Skip to content

Instantly share code, notes, and snippets.

@a14n
a14n / .travis.yml
Last active October 6, 2016 11:48
.travis.yml to run test in chrome
language: dart
sudo: required
dist: trusty
before_install:
- export CHROME_BIN=/usr/bin/google-chrome
- export DISPLAY=:99.0
- sh -e /etc/init.d/xvfb start
- sudo apt-get update
- sudo apt-get install -y libappindicator1 fonts-liberation
@a14n
a14n / .travis.yml
Last active August 29, 2015 14:20
Travis config to run tests on several platforms
language: dart
dart:
- stable
- dev
sudo: false
cache:
directories:
- $HOME/.pub-cache
with_content_shell: true
before_install:
@Namespace('z.y.x')
library js.example.js_proxy;
import 'package:js/js.dart';
part 'example.g.dart';
@JsProxy()
abstract class _JsFoo {
_JsFoo();
@a14n
a14n / js_list.dart
Last active August 29, 2015 14:07
List JsInterface over JsArray
import 'dart:collection';
import 'package:js/js.dart';
abstract class JsList<E> extends JsInterface with ListMixin<E> {
JsObject _js;
factory JsList() => new JsListImpl();
JsList.created(JsObject o) : _js = o, super.created(o);
@a14n
a14n / .gitconfig
Last active August 29, 2015 14:01
[core]
editor = vi
[alias]
st = status -sb
ll = log --decorate --graph --oneline
[color]
ui = auto
[push]
default = nothing
@a14n
a14n / index.html
Last active January 3, 2016 14:39
<x-route> polymer component
<!DOCTYPE html>
<link rel="import" href="route.html">
<script type="application/dart">export 'package:polymer/init.dart';</script>
<a href="#/home">Home</a>
<a href="#/list">List</a>
<hr>
<x-route></x-route>