Sto usando ngOptions per creare un menu di selezione ma una delle mie etichette ha un'entità HTML al suo interno &
. L'etichetta si presenta come Books & Stuff
non Books & Stuff
. My jade is this:Come utilizzare ngOptions con una stringa che contiene entità HTML?
select(ng-show="isType === 'select'", id="{{id}}", ng-model="model", ng-options="o.id as o.label for o in options")
Come posso visualizzare correttamente le entità HTML?
Aggiornamento
sto cercando la risposta da SAL:
select(ng-show="isType === 'select'", id="{{id}}", ng-model="model")
option(ng-repeat="o in options", ng-bind-html="o.label", value="{{o.id}}")
An questa mostra l'entità html corretto, ma l'opzione corretta non è selezionata più in base al modello . Vedere http://jsfiddle.net/ucLvjvkn/1/ per esempio.
Versione AngularJS? – tasseKATT