バージョン 3.5.1 を使用しています。両方使ってみた
enable: false
と
disable: true
しかし、どちらも機能していないようです。これが私のコードのスニペットです。
var select2Node = $element[0].firstChild;
$(select2Node).select2({
data: choices,
// Suppress the search box.
minimumResultsForSearch: -1,
allowClear: false,
width: '200px',
disable: true,
formatSelection: function(object, container) {
return $filter('truncateAtFirstInput')(object.id);
}
});