20

AngularJS の 2 つのバインドが div で機能しません。div を編集可能にしたいのですが、うまくいきません。誰が何が間違っているのか提案してもらえますか? テキストボックスでも同じバインディングがうまく機能します。これは私のコードです:

<input type="text" ng-model="userProfile.firstName"/>
<div class="profile-name" contenteditable="true" ng-model="userProfile.firstName"></div> 
4

3 に答える 3