Skip to content

Instantly share code, notes, and snippets.

View eirikb's full-sized avatar

Eirik Brandtzæg eirikb

  • Softeria AS
  • Ålesund, Norway
View GitHub Profile
@eirikb
eirikb / vuetwo.md
Created July 28, 2016 21:38
vuetwo source

vuetwo

Proof of concept library for building vue apps.
Basically a hacked together wrapper around rollup + rollup-watch with predefined setup.
vue template plugin is a slightly modified version of the new vue-template-compiler.

@eirikb
eirikb / vuetwo.md
Last active July 28, 2016 21:39
vuetwo - demo

vuetwo demo

Proof of concept vue for the lazy

Usage

  1. Download zip
  2. npm install
  3. npm start
@eirikb
eirikb / demo.md
Last active January 28, 2017 13:53
Demo of clicktest.sh

#Demo

##About The demo is meant to show how to make an automated answer to a hn comment, translated from Norwegian to English with these steps:

  1. Click on Chrome address bar.
  2. Type translate.google.com and press enter.
  3. Click on input field.
  4. Type the text for translation and wait for it to translate.
@eirikb
eirikb / clicktest.md
Last active April 9, 2021 16:49
Automated click testing in bash

About

This is a bash script, as an example, on how to do click-testing GUI based on finding components based on how they look.

Dependencies

  1. Download zip.
  2. npm install.
  3. npm start.
@eirikb
eirikb / JSPM+AVA.md
Last active June 11, 2017 21:30
JSPM + AVA
  1. Download zip.
  2. npm install.
  3. npm test.
@eirikb
eirikb / gulpfile.js
Last active September 26, 2017 21:25
Gulp + Babel + JSX
var gulp = require('gulp');
var fs = require('fs');
var browserify = require('browserify');
var babelify = require('babelify');
var watchify = require('watchify');
var source = require('vinyl-source-stream');
var livereload = require('gulp-livereload');
var less = require('gulp-less');
var concat = require('gulp-concat');
var connect = require('gulp-connect');
@eirikb
eirikb / example.js
Last active August 29, 2015 14:17
nodify
var nodify = require('nodify');
// Prints build time
console.log(nodify(function() {
return new Date();
}));
// Prints current time
console.log(new Date());
@eirikb
eirikb / paging.html
Created November 16, 2014 22:15
SharePoint paging
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.1/css/bootstrap.min.css">
<script src="//cdnjs.cloudflare.com/ajax/libs/underscore.js/1.7.0/underscore-min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/angular.js/1.3.0/angular.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/angular.js/1.3.0/angular-sanitize.min.js"></script>
<div ng-app="test-paging" ng-controller="ListController">
<table class="table table-bordered">
<tr ng-repeat="item in items">
<td>{{item.Title}}</td>
<td ng-bind-html="item.Body"></td>
</tr>
@eirikb
eirikb / dep.js
Created June 24, 2014 10:39
Dependencyhackjection
var d={a:1,b:2},f=function(a,b){return a+b};f.apply(null,(''+f).match(/function[^(]*\(([^)]*)\)/)[1].split(/,\s*/).map(function(x){return d[x]}))