Skip to content

Instantly share code, notes, and snippets.

🏠
Working from home

Kurtis Rainbolt-Greene krainboltgreene

🏠
Working from home
Block or report user

Report or block krainboltgreene

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 gist:8b55c096ef3f90479dcb9f400fc33509
krainboltgreene@lovelace.lan at ~/Code/unctionjs/_tempLate on ± core 𝑓 1 npm audit fix
npm ERR! code ELOCKVERIFY
npm ERR! Errors were found in your package-lock.json, run npm install to fix them.
npm ERR! Missing: babel-plugin-transform-object-rest-spread@6.26.0
npm ERR! Missing: babel-preset-flow@6.23.0
npm ERR! Missing: chokidar-cli@1.2.0
npm ERR! Missing: eslint@4.7.2
npm ERR! Missing: eslint-plugin-babel@4.1.2
npm ERR! Missing: eslint-plugin-immutable@1.0.0
npm ERR! Missing: flow@0.2.3
View patchtree-1.js
// KeyChain:: Array<mixed>
// Before:: mixed
// After:: Mixed
// Replacements:: Map<Before, After>
// patchTree:: (Map<KeyChain, Replacements>) => Object => Object
View .hyper.js
// Future versions of Hyper may add additional config options,
// which will not automatically be merged into this file.
// See https://hyper.is#cfg for all currently supported options.
module.exports = {
config: {
// Choose either "stable" for receiving highly polished,
// or "canary" for less polished but more frequent updates
updateChannel: 'stable',
View gist:eb5cf8331abb76371469e7c0d29234d2
[1] pry(main)> module Behavior
[1] pry(main)* extend ActiveSupport::Concern
[1] pry(main)*
[1] pry(main)* included do
[1] pry(main)* add(1)
[1] pry(main)* end
[1] pry(main)*
[1] pry(main)* class_methods do
[1] pry(main)* def add(value)
[1] pry(main)* @value = value
View add_to_cart_operation.rb
# NOTE: Each task is a map function wrapped in a HOC for handling the return data.
# The annotation of each task is `state -> mixed | state | exception` and the HOC is
# `state -> (state -> mixed | exception) -> state`. `error` is like a task, but instead:
# `exception -> mixed` wrapped in a HOC that matches `exception -> (exception -> mixed) -> exception`.
class AddToCartOperation < ApplicationOperation
task :check_for_missing_product
task :carbon_copy_cart_item
task :lock
task :persist
View challenge.rb
require "set"
require "rspec/autorun"
GRAPH = Hash.new { |accumulated, key| accumulated[key] = Set.new}
LIBRARIES = Set.new
def depend(subject, *dependencies)
GRAPH[subject].merge(dependencies)
dependencies.each(&GRAPH.method(:[]))
end
View README.md

smart_params

  • Build
  • Downloads
  • Version

Work smart, not strong. This gem gives developers an easy to understand and easy to maintain schema for request parameters. Meant as a drop-in replacement for strong_params.

View gist:81c70c7c7dbad8cde10dd45543ce046e
SmartParams
returns as json (FAILED - 1)
Failures:
1) SmartParams returns as json
Failure/Error:
expect(
CreateAccountSchema.new({
data: {
View README.md

smart_params

  • Build
  • Downloads
  • Version

Work smart, not strong. This gem gives developers an easy to understand and easy to maintain schema for request parameters. Meant as a drop-in replacement for strong_params.

View reducers.js
export {default as updateInput} from "./updateInput"
export {default as submitAccount} from "./submitAccount"
You can’t perform that action at this time.