2013-02-23から1日間の記事一覧
ヒアドキュメントの変数埋め込みで 変数がないばあいnullにしたりとか int = 12 str = """ #{if int? then "'#{int}'" else null} #{if nothing? then "'#{nothing}'" else null} """ console.log strこうなる '12' null
ヒアドキュメントの変数埋め込みで 変数がないばあいnullにしたりとか int = 12 str = """ #{if int? then "'#{int}'" else null} #{if nothing? then "'#{nothing}'" else null} """ console.log strこうなる '12' null