Skip to content

Instantly share code, notes, and snippets.

View taisyo7333's full-sized avatar

Daisuke Inoue taisyo7333

View GitHub Profile
@taisyo7333
taisyo7333 / gist:db468b21158ca82dd5d80af1609d7568
Created April 15, 2016 03:57
Rails Minitest debugging on console
$stdout.puts e.class
$stdout.puts e.message
@taisyo7333
taisyo7333 / gist:08d43bf1e66a2b84f0238ac639d4169d
Created April 8, 2016 08:26
コーディング:英語
http://qiita.com/sue738/items/9754b3cad13272bd3d39
最上位のcomponentにconnectを行う。propsを通して、state,actionを引き渡す。
https://tongariboyz.gitbooks.io/react-native-redux-dev-notes/content/ja/smartAndDumbComponent.html
http://qiita.com/kiita312/items/d769c85f446994349b52#container-and-presentational-components
@taisyo7333
taisyo7333 / command_line.log
Created March 29, 2016 09:14
docker上でrails console起動する
docker-compose run app rails console
@taisyo7333
taisyo7333 / dump(Add Suppoted Orietation 2).log
Last active March 25, 2016 01:03
react-native-orientation Lock to LandScapeによる例外発生
2016-03-25 08:54:38.640 [info][tid:com.facebook.React.JavaScript] Running application "landscape_test" with appParams: {"rootTag":1,"initialProps":{}}. __DEV__ === true, development-level warning are ON, performance optimizations are OFF
2016-03-25 08:54:38.651 landscape_test[5155:66368] Locked to Landscape
2016-03-25 08:54:38.658 landscape_test[5155:66197] *** Terminating app due to uncaught exception 'UIApplicationInvalidInterfaceOrientation', reason: 'Supported orientations has no common orientation with the application, and [RCTModalHostViewController shouldAutorotate] is returning YES'
*** First throw call stack:
(
0 CoreFoundation 0x000000010ef7ed85 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x000000010e176deb objc_exception_throw + 48
2 CoreFoundation 0x000000010ef7ecbd +[NSException raise:format:] + 205
3 UIKit 0x0000000110f45e36 -[UIViewController __supportedInterfaceOrientations] + 903
4 UIK
@taisyo7333
taisyo7333 / memo.txt
Last active March 2, 2016 07:02
React Native Memo
react-native-sound のLoadは非同期。
<Image> using local image file
https://github.com/facebook/react-native/issues/751
<Image style={styles.hoge} source={{isStatic:true, uri:"/tmp/image/hoge.jpg"}} />
https://github.com/goatslacker/alt/issues/283
http://egorsmirnov.me/2015/08/16/react-and-es6-part3.html
@taisyo7333
taisyo7333 / Memo
Created February 24, 2016 02:39
JavScript 調べたこと。
調べた英単語
hoist [verb]
1. to raise (something) especially by using ropes or machinery
ロープなどを使って持ち上げる。
2. drink (informal)
3. to take a shot , (basketball , informal)
使用例) https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Classes
An important difference between function declarations and class declarations is that function declarations are hoisted and class declarations are not.
@taisyo7333
taisyo7333 / ruby_memo.txt
Created February 24, 2016 00:07
ruby memo
Ruby 既存ファイルを開く時のモードについて
"w" : 書き込みモード:既存ファイルの場合は、ファイルの内容を空にする。
"w+": 読み書きモード:既存ファイルの場合は、ファイルの内容を空にする。
"r+": 読み書きモード:ファイルの読み書き位置が戦闘になる。
"a" : 追記モード  :常にファイルの末尾に追加
"a+": 読み書きモード:ファイルの読み込み位置は先頭。書き込み位置は常に末尾。
@taisyo7333
taisyo7333 / ruby_exam_002_File_join.rb
Last active February 22, 2016 23:22
Ruby 悩んだこと #2
File.join("/","g") # => /g
File.join("a","g") # => a/g
File.join("","g") # => /g
File.join("","g","") # => /g/
File.join("","","g","") # => /g/