This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* react-select + allOption | |
* | |
* author: alex.escalante@gmail.com, @alex_escalante | |
* | |
* Gives users of the fine component react-select the ability to select | |
* all options with a single click. | |
* | |
* We're basically wrapping react-select but using a special option, | |
* the "allOption". This option is exclusive of any other option |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = { | |
default: { | |
// versionify will replace the following string with the actual version number | |
BUILD_VERSION: '__VERSION__' | |
}, | |
development: { | |
API_URL: 'http://localhost:3000' | |
}, | |
production: { | |
API_URL: 'http://acme.com' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require_relative '../life_window.rb' | |
RSpec.describe LifeWindow do | |
describe "#count_around" do | |
it "counts elements around, not ibcluding, the specified coordinate" do | |
m1 = Matrix[[false, true, false], [true, true, true], [false, true, false]] | |
m2 = Matrix[[false, false, false], [true, true, true], [false, true, false]] | |
m3 = Matrix[[false, false, false], [true, true, true], [false, false, false]] | |
expect(LifeWindow.count_around(m1, 1, 1)).to eq(4) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
puts (1..100).map &-> e { e % 15 == 0 ? :fizzbuzz : e % 3 == 0 ? :fizz : e % 5 == 0 ? :buzz : e } |