JSFiddle - React, Tailwind, and code Playground
HTML
<link rel="stylesheet" href="http://semantic-ui.com/dist/semantic.css">
<script src="http://semantic-ui.com/dist/semantic.js"></script>
<select name="tags" multiple="" class="ui fluid dropdown">
<option value="" >Enter some tags</option>
<option value="css">css</option>
<option value="html">html</option>
</select>
<br>
<p>
python and ruby should be selected but they are just added to the dropdown.
</p>
CSS
body {
padding: 1em;
}
JavaScript
$dropdown = $('.ui.dropdown');
$dropdown.dropdown({
maxSelections: 3
});
$dropdown.dropdown('add optionValue', 'ruby');
$dropdown.dropdown('add optionValue', 'python');
$dropdown.dropdown('set selected', ['css', 'html', 'python', 'ruby']);