Created
October 25, 2013 05:57
-
-
Save wilf312/7150019 to your computer and use it in GitHub Desktop.
CoffeeScriptでヒアドキュメントで変数展開させる ref: http://qiita.com/wilf312/items/1476ec927df22bab5392
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
insert = '展開したいテキスト' | |
# 出力 → ここに展開したいテキストをいれます。 | |
ex1 = """ | |
ここに#{insert}をいれます。 | |
""" | |
console.log(ex1); | |
# 出力 → ここには#{insert}入りません。 | |
ex2 = ''' | |
ここには#{insert}入りません。 | |
''' | |
console.log(ex2); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment