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


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="grych" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/grych/120/5610_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  grych
                  </h3>
		          </div>
						
			          <div class="user-title">
									<span>Creator of Drab</span>
			          </div>
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group" data-username="wlminimal" data-post="11" data-topic="15168">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/letter_avatar_proxy/v4/letter/w/958977/48.png" class="avatar"> wlminimal:</div>
<blockquote>
<pre data-code-wrap="elixir"><code class="lang-elixir">iex(5)&gt; Drab.Config.get(TextingWeb.Endpoint, :access_session)
[]
</code></pre>
<p>in config.exs</p>
<pre data-code-wrap="elixir"><code class="lang-elixir">config :drab, TextingWeb.Endpoint,
  otp_app: :texting,
  access_session: [:user_id]
</code></pre>
</blockquote>
</aside>
<p>This is getting even stranger. What version of Drab are you running?</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="88594" 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/drab-how-to-get-a-conn-value/15168/12">Post #11</a>
	                </div>
	            </div>
              <div id="likers-container-88594" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="88594"
                     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="88602" data-post-id="88602">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="grych" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/grych/120/5610_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  grych
                  </h3>
		          </div>
						
			          <div class="user-title">
									<span>Creator of Drab</span>
			          </div>
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Actually, I can’t reproduce this issue. In my environment all works as expected: the other form values (name, description) are kept.</p>
<p>The only reason why this value may be cleared, is when Drab decides to refresh them. This may be because the form may be under some other expression. Imagine something like:</p>
<pre data-code-wrap="html"><code class="lang-html">&lt;%= if @short_url do %&gt;
  &lt;input id=other&gt;
  &lt;input value=&lt;%= @long_url%&gt; id=long_url&gt;
  &lt;input value=&lt;%= @short_url%&gt; id=short_url&gt;
&lt;% end %&gt;
</code></pre>
<p>Now, when you <code>poke socket, long_url: ...</code>, everything will work as expected: the only <code>&lt;input id=long_url&gt;</code> is going to be updated. So the other input value will be untouched.</p>
<p>But what when you <code>poke socket, short_url: ...</code>? Drab will update <strong>everything under if</strong>, so all three inputs will be refreshed! This will re-set their values.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="88602" data-batch-url="/posts/batch_likers">
                        1
                      </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/drab-how-to-get-a-conn-value/15168/13">Post #12</a>
	                </div>
	            </div>
              <div id="likers-container-88602" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="88602"
                     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>