Skip to content

Instantly share code, notes, and snippets.

Avatar

Wesley Workman workmanw

View GitHub Profile
@workmanw
workmanw / components.test-one.js
Created Dec 10, 2016 — forked from 3AHAT0P/components.test-one.js
Ember 2.10.0 - Bug with inline styles
View components.test-one.js
import Ember from 'ember';
export default Ember.Component.extend({
attributeBindings: 'style'.w(),
init() {
this._super(...arguments);
Ember.run.later(this, () => {
this.set('isVisible', true);
}, 5000);
View components.one-way-input.js
import Ember from 'ember';
export default Ember.Component.extend({
tagName: 'input',
attributeBindings: [ 'type', 'value', 'placeholder', 'data-stripe', 'name' ],
type: 'text',
_sanitizedValue: undefined,
input() { this._handleChangeEvent(); },
change() { this._handleChangeEvent(); },
View application.controller.js
import Ember from 'ember';
export default Ember.Controller.extend({
appName:'Ember Twiddle'
});
View pr.md

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

View gist:1511429
var B = {
foo: function (original) {
console.log("Foo B");
original();
}.enhance()
};
var C = {
foo: function () {
console.log("Foo C");
View gist:1443161
var g = require('../garcon/lib/garçon');
var myapp;
var combineScripts = false;
//var shouldBuild = false;
//var stdHtmlBody = [
//'<div id="loading">',
//'<p id="loading">',
//'Loading…',
View gist:1424791
var g = require('../garcon/lib/garçon');
var server = g.Server.create({proxyHost: 'localhost', proxyPort: 8080});
var myapp;
var shouldBuild = false;
var stdHtmlBody = [
 '<div id="loading">',
   '<p id="loading">',
   'Loading…',
@workmanw
workmanw / gist:1419845
Created Dec 1, 2011 — forked from tim-evans/gist:1419818
hashFor & guidFor optimizations
View gist:1419845
diff --git a/frameworks/runtime/core.js b/frameworks/runtime/core.js
index 2d12957..4b553f4 100644
--- a/frameworks/runtime/core.js
+++ b/frameworks/runtime/core.js
@@ -316,8 +316,6 @@ SC.mixin(/** @scope window.SC.prototype */ {
guidKey: "SproutCore" + ( SC.VERSION + Math.random() ).replace( /\D/g, "" ),
// Used for guid generation...
- _guidPrefixes: {"number": "nu", "string": "st"},
- _guidCaches: {"number": {}, "string": {}},
@workmanw
workmanw / followup.handlebars
Created Nov 30, 2011 — forked from lxcodes/followup.handlebars
Trouble With Sproutcore Template Views inside Core
View followup.handlebars
<div>
Hello, <b>{{text}}</b>!
</div>
@workmanw
workmanw / tasks.js
Created Jul 22, 2011 — forked from tritchey/tasks.js
filtering
View tasks.js
ScaleUI.taskTagController = SC.ArrayController.create(
/** @scope ScaleUI.taskTagController.prototype */ {
queuedTasks: function() {
return content.filterProperty('state', TaskState.QUEUED);
}.property('@each.state').cacheable(),
runningTasks: function() {
return content.filterProperty('state', TaskState.RUNNING);
}.property('@each.state').cacheable(),