Skip to content

Instantly share code, notes, and snippets.

View jambutler's full-sized avatar

Jim Butler jambutler

  • Boston, MA
View GitHub Profile
@jambutler
jambutler / app.html
Last active November 1, 2016 17:45
AuthorizationService with object sharing problem
<template>
<nav class="navbar navbar-default navbar-fixed-top" role="navigation">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
<span class="sr-only">Toggle Navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
@jambutler
jambutler / AuthService.js
Last active October 28, 2016 19:41
AuthorizationService
import { Aurelia, inject } from 'aurelia-framework';
import { HttpClient } from 'aurelia-http-client';
//import {HttpClient} from 'aurelia-fetch-client';
import config from 'config';
@inject(Aurelia, HttpClient)
export default class AuthService {
session = null
@jambutler
jambutler / index.html
Created October 27, 2016 20:09
Auth Service
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>GistRun</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
<h1>Hello world!</h1>
<script src="script.js"></script>
<template>
<table>
<thead>
<tr>
<td>Planet</td>
<td>Diameter (mi)</td>
<td>Distance to Sun (mi)</td>
</tr>
</thead>
<tbody>
<template>
<require from="./textbox"></require>
<form submit.delegate="submit()">
<ul><li repeat.for="error of controller.errors">${error.message}</li></ul>
<textbox value.bind="firstName & validate" label="First Name"></textbox>
<textbox value.bind="lastName & validate" label="Last Name"></textbox>
@jambutler
jambutler / app.html
Created August 18, 2016 18:13 — forked from jdanyow/app.html
Aurelia Fetch Client Gist
<template>
<h1>${message}</h1>
<ul>
<li repeat.for="user of users">
${user.login}
</li>
</ul>
</template>
<template>
<router-view layout-view="default.html"></router-view>
</template>