<turbo-stream action="append" target="posts_list"><template>    <div class="postbit" id="30577" data-post-id="30577">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="vonH" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  vonH
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group quote-modified" data-username="net" data-post="9" data-topic="4718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/net/48/429_2.png" class="avatar"> net:</div>
<blockquote>
<p>|&gt; inspect(limit: :infinity) \ <br>
|&gt; (&amp;(&amp;1 &lt;&gt; “\n”)).() <br>
|&gt; (&amp;File.write(“output.txt”, &amp;1)).()</p>
</blockquote>
</aside>
<p>The input is coming from a CSV file so there is no way to tell the exact headers before hand for this line to be generated.</p>
<p><code>|&gt; Stream.map(fn(struct) -&gt; "iso: #{struct.iso}, name: #{struct.name}\n" end) \</code></p>
<p>Unless some function is used to read the first line for the headers and generate the equivalent code and structures beforehand.</p>
<p>The option in response no 8 works, but it is all a single line. Will there be some way print each struct on a single line?</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="30577" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/12">Post #11</a>
	                </div>
	            </div>
              <div id="likers-container-30577" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="30577"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #11"></div>
  </section>
</div>
    <div class="postbit" id="30578" data-post-id="30578">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="vonH" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  vonH
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group" data-username="net" data-post="11" data-topic="4718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/net/48/429_2.png" class="avatar"> net:</div>
<blockquote>
<p>inspect(limit: :infinity) comes after Enum.list. If you don’t need the Elixir syntax to be a part of the output though, I would highly recommend using one of the options.</p>
</blockquote>
</aside>
<p>Does this mean the code can be applied to any output from the code, ie any thing output by the code to the screen?</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="30578" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/13">Post #12</a>
	                </div>
	            </div>
              <div id="likers-container-30578" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="30578"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #12"></div>
  </section>
</div>
    <div class="postbit" id="30583" data-post-id="30583">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="net" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/net/120/429_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  net
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Presumably you would know the headers (you will certainly know the struct fields if you’re using <code>.structs_from_csv</code>). If not, you can do</p>
<pre><code>|&gt; Stream.map(&amp;inspect/1) \
</code></pre>
<p>or</p>
<pre><code>|&gt; Stream.map(&amp;(&amp;1 |&gt; Map.from_struct |&gt; Enum.reduce("", fn({k, v}, acc) -&gt; "#{acc}#{k}: #{v}, " end) |&gt; String.slice(0..-3))) \
</code></pre>
<p>(for cleaner formatting) instead.</p>
<aside class="quote no-group" data-username="vonH" data-post="12" data-topic="4718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/letter_avatar_proxy/v4/letter/v/bc79bd/48.png" class="avatar"> vonH:</div>
<blockquote>
<p>The option in response no 8 works, but it is all a single line. Will there be some way print each struct on a single line?</p>
</blockquote>
</aside>
<p>You could try <code>inspect(limit: :infinity, pretty: true, width: 60)</code> (mess with <code>width</code>).</p>
<aside class="quote no-group quote-modified" data-username="vonH" data-post="13" data-topic="4718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/letter_avatar_proxy/v4/letter/v/bc79bd/48.png" class="avatar"> vonH:</div>
<blockquote>
<blockquote>
<p>inspect(limit: :infinity) comes after Enum.list. If you don’t need the Elixir syntax to be a part of the output though, I would highly recommend using one of the options.</p>
</blockquote>
<p>Does this mean the code can be applied to any output from the code, ie any thing output by the code to the screen?</p>
</blockquote>
</aside>
<p>Yes.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="30583" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/14">Post #13</a>
	                </div>
	            </div>
              <div id="likers-container-30583" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="30583"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #13"></div>
  </section>
</div>
    <div class="postbit" id="30656" data-post-id="30656">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="vonH" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  vonH
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group quote-modified" data-username="net" data-post="9" data-topic="4718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/net/48/429_2.png" class="avatar"> net:</div>
<blockquote>
<p>|&gt; (&amp;(&amp;1 &lt;&gt; “\n”))</p>
</blockquote>
</aside>
<p>Does this line mean a function which appends a <code>newline</code> to the input, assuming that <code>&amp;1</code> refers to the first parameter?</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="30656" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/15">Post #14</a>
	                </div>
	            </div>
              <div id="likers-container-30656" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="30656"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #14"></div>
  </section>
</div>
    <div class="postbit" id="30658" data-post-id="30658">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="vonH" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  vonH
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group quote-modified" data-username="net" data-post="14" data-topic="4718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/net/48/429_2.png" class="avatar"> net:</div>
<blockquote>
<p>The option in response no 8 works, but it is all a single line. Will there be some way print each struct on a single line?</p>
<p>…<br>
|&gt; Enum.to_list <br>
|&gt; inspect(limit: :infinity) \ <br>
|&gt; (&amp;(&amp;1 &lt;&gt; “\n”)).() <br>
|&gt; (&amp;File.write(“output.txt”, &amp;1)).()</p>
<p>You could try inspect(limit: :infinity, pretty: true, width: 60) (mess with width).</p>
</blockquote>
</aside>
<p>The Enum.to_list function starts the printing of each new struct on a new line, but <code>inspect(limit: :infinity) \ </code> appears to remove them before they get to the <code>(&amp;File.write("output.txt", &amp;1)).()</code>.</p>
<p>Is there an alternative that will maintain the line breaks?</p>
<p>Can the output of <code>Enum.to_list</code> be written directly to a file without the <code>inspect</code> removing the line breaks?</p>
<p>The structs are separated at <code>},</code>. How would a search and replace to replace them with <code>},\n</code> be written (assumes that <code>\n</code> is the right code for a line break?</p>
<p>How would I place the output of <code>inspect(limit: :infinity) \ </code> into a variable and run the search and replace for  <code>},</code> with  <code>},\n</code> before the file write?</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="30658" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/16">Post #15</a>
	                </div>
	            </div>
              <div id="likers-container-30658" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="30658"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #15"></div>
  </section>
</div>
    <div class="postbit" id="30674" data-post-id="30674">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="OvermindDL1" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/OvermindDL1/120/2677_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  OvermindDL1
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group" data-username="vonH" data-post="16" data-topic="4718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/letter_avatar_proxy/v4/letter/v/bc79bd/48.png" class="avatar"> vonH:</div>
<blockquote>
<p>Can the output of Enum.to_list be written directly to a file without the inspect removing the line breaks?</p>
</blockquote>
</aside>
<p>You can JSON’ify it and send it through a formatter.<br>
Or you can parse out each list individually, maybe by replacing your inspect line with this one instead:</p>
<pre data-code-wrap="elixir"><code class="lang-elixir">|&gt; (fn l -&gt;[?[, Enum.map(l, &amp;([inspect(limit: :infinity), ?\n])), ?]] end).()
</code></pre>
<p>Or something like that (untested code), or grab a formatting library.  ^.^</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="30674" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/17">Post #16</a>
	                </div>
	            </div>
              <div id="likers-container-30674" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="30674"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #16"></div>
  </section>
</div>
    <div class="postbit" id="30757" data-post-id="30757">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="vonH" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  vonH
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>I finally got the main logic of the working with this code.</p>
<pre><code>File.stream!('tmp.csv') \
|&gt; DataMorph.structs_from_csv("open-register", :iso_country) \
|&gt; Enum.map(fn(x) -&gt; inspect(x, [limit: :infinity])&lt;&gt;",\n" end) \
|&gt; (&amp;File.write('output.txt',&amp;1)).()
</code></pre>
<p>Each line is appended with a comma. What I want to do now is to add an opening bracket for the list <code>[</code>, ignore  the comma on the last item <code>,</code> and add the closing bracket `]'.</p>
<pre><code>1. if it is the first item prepend the '['.
2. output the item
3. if is not the last item append a `,`
4. if all have been added, append the closing `]`.
</code></pre>
<p>How can I do that in snazzy one-liner. In the same pipelined set of functions. I want to do it in a more <code>functional style</code> , not I would normally do it in procedural languages.</p>
<p>The normal way is to ascertain the size of the list, set a variable to the no of items processed, if 0 items, prepend the <code>[</code>, print the item, increment the printed count, if not same as no of items, append the the <code>,</code> , of the last tiem append the closing bracket. This approach can be prone to off by one errors, which is why I want to try a more functional style.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="30757" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/18">Post #17</a>
	                </div>
	            </div>
              <div id="likers-container-30757" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="30757"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #17"></div>
  </section>
</div>
    <div class="postbit" id="30760" data-post-id="30760">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="vonH" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  vonH
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>I am beginning to get the hang of your formula after realizing that the ?[ and ?\n refer to unicode code points.</p>
<pre><code>File.stream!('tmp.csv') \
|&gt; DataMorph.structs_from_csv("open-register", :iso_country) \
|&gt; (fn l -&gt;[?[, Enum.map(l, &amp;([inspect(limit: :infinity), ?\n])), ?]] end).()
|&gt; (&amp;File.write('output.txt',&amp;1)).()
</code></pre>
<p>When I apply your formula this is the message error:</p>
<pre><code>* (CompileError) iex:55: invalid args for &amp;, expected an expression in the format of &amp;Mod.fun/arity, &amp;local/arity or a capture containing at least one argument as &amp;1, got: [inspect(limit: :infinity), 10]
    (elixir) expanding macro: Kernel.|&gt;/2
             iex:55: (file)
</code></pre>
<p>It is a syntax error which doesn’t get to compile.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="30760" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/19">Post #18</a>
	                </div>
	            </div>
              <div id="likers-container-30760" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="30760"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #18"></div>
  </section>
</div>
    <div class="postbit" id="30888" data-post-id="30888">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="OvermindDL1" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/OvermindDL1/120/2677_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  OvermindDL1
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Uh sorry, like I said untested code.  ^.^;</p>
<p>The:  <code>inspect(limit: :infinity)</code><br>
Should be:  <code>inspect(&amp;1, limit: :infinity)</code></p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="30888" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/20">Post #19</a>
	                </div>
	            </div>
              <div id="likers-container-30888" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="30888"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #19"></div>
  </section>
</div>
    <div class="postbit" id="31033" data-post-id="31033">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="vonH" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  vonH
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>I got a complete program from Dogbert at stackoverflow.</p>
<aside class="onebox stackexchange" data-onebox-src="https://stackoverflow.com/questions/43568312/what-is-the-correct-syntax-for-this-elixir-expression">
  <header class="source">

      <a href="https://stackoverflow.com/questions/43568312/what-is-the-correct-syntax-for-this-elixir-expression" target="_blank" rel="noopener nofollow ugc">stackoverflow.com</a>
  </header>

  <article class="onebox-body">
      <a href="https://stackoverflow.com/users/172406/vfclists" target="_blank" rel="noopener nofollow ugc">
    <img alt="vfclists" src="https://www.gravatar.com/avatar/e750df851299d1c7d627f063a6e46980?s=256&amp;d=identicon&amp;r=PG" class="thumbnail onebox-avatar" width="256" height="256">
  </a>

<h4>
  <a href="https://stackoverflow.com/questions/43568312/what-is-the-correct-syntax-for-this-elixir-expression" target="_blank" rel="noopener nofollow ugc">What is the correct syntax for this Elixir expression?</a>
</h4>

<div class="tags">
  <strong>elixir, anonymous-function</strong>
</div>

<div class="date">
  asked by
  
  <a href="https://stackoverflow.com/users/172406/vfclists" target="_blank" rel="noopener nofollow ugc">
    vfclists
  </a>
  on <a href="https://stackoverflow.com/questions/43568312/what-is-the-correct-syntax-for-this-elixir-expression" target="_blank" rel="noopener nofollow ugc">07:02AM - 23 Apr 17 UTC</a>
</div>

  </article>

  <div class="onebox-metadata">
    
    
  </div>

  <div style="clear: both"></div>
</aside>

<p>Does Dogbert lurk hereabouts under a different name</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="31033" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/how-can-i-stream-the-output-of-enum-to-list-to-text-for-insertion-into-an-editor/4718/21">Post #20</a>
	                </div>
	            </div>
              <div id="likers-container-31033" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="31033"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-last-post cat-last-post" title="Last post!"></div>
  </section>
</div>
</template></turbo-stream><turbo-stream action="replace" target="load-more-container"><template><div id="load-more-container" class="load-more-container">
    <span class="all-loaded">— All posts loaded —</span>
</div></template></turbo-stream>