<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>necojackarc</author_name>
  <author_url>https://blog.hatena.ne.jp/necojackarc/</author_url>
  <blog_title>Taka の日記帳</blog_title>
  <blog_url>https://necojackarc.hatenablog.com/</blog_url>
  <categories>
    <anon>ITライフ</anon>
  </categories>
  <description>Ruby では大きく分けて3種類の文字列リテラル*1がありますが、どのように使い分けるのが適切か、自分なりの結論に達したのでまとめておきます。 結論 まず先に結論から書いておくと*2、 基本はダブルクオートを使用する 意図的に式展開を抑制したい場合にのみシングルクオートを使用する が最も適切な使い分けだと思います。 これは、Ruby Style Guide の 文字列リテラルスタイルの Option B と同じです。 文字列中に&quot;を含んでいたり、エスケープ文字を抑えたいときでない限り、 ダブルクォーテーションが好まれます。 一貫した文字列リテラル - Ruby Style Guide つまり、…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fnecojackarc.hatenablog.com%2Fentry%2F2015%2F09%2F12%2F220832&quot; title=&quot;Rubyの文字列リテラルではダブルクオートを基本としたい - Taka の日記帳&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2015-09-12 22:08:32</published>
  <title>Rubyの文字列リテラルではダブルクオートを基本としたい</title>
  <type>rich</type>
  <url>https://necojackarc.hatenablog.com/entry/2015/09/12/220832</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
