Skip to content

Instantly share code, notes, and snippets.

View kiwiupover's full-sized avatar
😁
Kia Kaha!

Dave Laird kiwiupover

😁
Kia Kaha!
View GitHub Profile
/* global google */
var GoogleMapComponent = Ember.Component.extend({
places: [],
width: 500,
height: 500,
attributeBindings: ['style'],
style: function () {
return 'width:'+this.width+'px; height:'+this.height+'px';
@fotinakis
fotinakis / freeze-moment.js
Last active April 10, 2017 23:54
Ember freezeMoment test helper
import Ember from 'ember';
import {
beforeEach,
afterEach
} from 'mocha';
// Support for overriding the baseline time used by Moment.js. Accepts ISO formatted timestamps.
//
// Requires:
// moment >= 2.11.0 in order to override moment.now.

This document has moved!

It's now here, in The Programmer's Compendium. The content is the same as before, but being part of the compendium means that it's actively maintained.

How to use positionalParams in Angle Bracket invocation

A component with positionalParams always also has named versions of its parameters. For example, the liquid-if component from liquid-fire has this in its Javascript file:

positionalParams: ['predicate']

So these are equivalent: