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
### Keybase proof | |
I hereby claim: | |
* I am antonzhyliuk on github. | |
* I am antonzhyliuk (https://keybase.io/antonzhyliuk) on keybase. | |
* I have a public key ASDoxzyIPBjaTBW2g8xg3L9xaoMj_t_YU8IPbYW9ZPr2_Ao | |
To claim this, I am signing this object: |
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
(ns forest-community.components.camera | |
(:require [reagent.core :as r])) | |
(def ReactNative (js/require "react-native")) | |
(def text (r/adapt-react-class (.-Text ReactNative))) | |
(def view (r/adapt-react-class (.-View ReactNative))) | |
(def react-native-camera (js/require "react-native-camera")) | |
(def camera (-> react-native-camera | |
.-default |
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
def dice_roll_chance_combined(dice_count:, expected_value:) | |
return 0.0 unless (dice_count..dice_count * 6).include?(expected_value) | |
if dice_count == 1 | |
(1.to_f / 6).round(4) | |
elsif dice_count >= 5 | |
dice_roll_chance_by_combinatorics(dice_count: dice_count, expected_value: expected_value) | |
else | |
dice_roll_chance_by_enumeration(dice_count: dice_count, expected_value: expected_value) | |
end | |
end |
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
=Navigating= | |
visit('/projects') | |
visit(post_comments_path(post)) | |
=Clicking links and buttons= | |
click_link('id-of-link') | |
click_link('Link Text') | |
click_button('Save') | |
click('Link Text') # Click either a link or a button | |
click('Button Value') |
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
=Navigating= | |
visit('/projects') | |
visit(post_comments_path(post)) | |
=Clicking links and buttons= | |
click_link('id-of-link') | |
click_link('Link Text') | |
click_button('Save') | |
click('Link Text') # Click either a link or a button | |
click('Button Value') |