Skip to content

Instantly share code, notes, and snippets.

Toran Billups toranb

Block or report user

Report or block toranb

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View acceptance-test.rb
require 'watir-webdriver'
include Selenium
describe "Acceptance tests" do
before :each do
@b = Watir::Browser.new :firefox
end
after :each do
@b.close
View glimmerRedux.js
import Component, { tracked } from '@glimmer/component';
import { createStore } from 'redux';
const reducers = (state, action) => {
if(action.type === 'ADD') {
return state + 1;
}
return state || 0;
};
const store = createStore(reducers);
@toranb
toranb / index.js
Created Oct 7, 2017
post processing css with ember-cli to work around libsass blocker
View index.js
/* eslint-env node */
'use strict';
const path = require('path');
const replace = require('broccoli-replace');
const Merge = require('broccoli-merge-trees');
module.exports = {
name: 'replacc',
View actions.items.js
export const updateItem = (id, name) => dispatch => dispatch({type: 'UPDATE_ITEM', id, name});
export const toggleEdit = (id, value) => dispatch => dispatch({type: 'TOGGLE_EDIT', id, value});
View components.customize-me.js
import Ember from 'ember';
import hbs from 'htmlbars-inline-precompile';
import { connect } from 'ember-redux';
const stateToComputed = state => {
return {
name: state.data.name,
loading: state.data.loading
};
};
View components.dispatch-saga.js
import Ember from 'ember';
import hbs from 'htmlbars-inline-precompile';
import { connect } from 'ember-redux';
const stateToComputed = state => {
return {
number: state.saga.number,
loading: state.saga.loading
};
};
View actions.todos.js
import * as types from '../actions/types';
export const addTodo = text => dispatch => dispatch({type: types.ADD_TODO, text});
export const deleteTodo = id => dispatch => dispatch({type: types.DELETE_TODO, id});
export const editTodo = (id, text) => dispatch => dispatch({type: types.EDIT_TODO, id, text});
export const completeTodo = id => dispatch => dispatch({type: types.COMPLETE_TODO, id});
export const clearCompleted = () => dispatch => dispatch({type: types.CLEAR_COMPLETED});
export const showAll = () => dispatch => dispatch({type: types.SHOW_ALL});
export const showActive = () => dispatch => dispatch({type: types.SHOW_ACTIVE});
export const showCompleted = () => dispatch => dispatch({type: types.SHOW_COMPLETED});
@toranb
toranb / download.txt
Created Aug 29, 2017
simple dropbox public image file
View download.txt
https://u716525.dl.dropboxusercontent.com/u/716525/images/toranbillups.png
View components.number-count.js
import Ember from 'ember';
import hbs from 'htmlbars-inline-precompile';
import { connect } from 'ember-redux';
const stateToComputed = state => {
return {
number: state.number
};
};
You can’t perform that action at this time.