Skip to content

Commit a728d94

Browse files
committed
Added some content to the tagging section
1 parent 559a93b commit a728d94

1 file changed

Lines changed: 11 additions & 3 deletions

File tree

docs/examples.html

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -230,14 +230,22 @@ <h1>Tagging support</h1>
230230
</select>
231231
</p>
232232

233+
<p>
234+
Note that when tagging is enabled the user can select from pre-existing
235+
options or create a new tag by picking the first choice, which is what
236+
the user has typed into the search box so far.
237+
</p>
238+
233239
</div>
234240
<div class="col-md-8">
235241
<h2>Example code</h2>
236242

237-
<pre data-fill-from=".js-code-disabled-results"></pre>
238-
239-
<script type="text/x-example-code" class="js-code-data-disabled">
243+
<pre data-fill-from=".js-code-tags"></pre>
240244

245+
<script type="text/x-example-code" class="js-code-tags">
246+
$(".js-example-tags").select2({
247+
tags: true
248+
})
241249
</script>
242250
</div>
243251
</section>

0 commit comments

Comments
 (0)