Having a difficulty finding documentation on this, but in Angular 1 you could do:
<textarea ng-model="name" ng-list=","></textarea>
Then on input, if you were to enter "Hello, world!" name
would be an array of ["Hello", "world!"]
.
My goal is to use ng-list
with the HTML entity
for breaking a textarea
by line into an array. See example from docs.
Is there an equivalent of this in Angular 2?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…