Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error "Found 3 elements with non-unique id #input"

I'm using Polymer with Chrome 63.0.3239.108 (updated this morning) and I got some new errors while launching my webapp:

[DOM] Found 3 elements with non-unique id #input

Here's my code :

<div class="card-content" on-keypress="_keyHandler">
   <paper-input id="login" label="[[i18n('uid')]]"></paper-input>
   <paper-input id="pwd" label="[[i18n('pwd')]]" type="password"></paper-input>
   <paper-input id="server" label="[[i18n('server')]]"></paper-input>
</div>

Yeah, <paper-input> elements have the same id, but what can I do to remove this console error?

Thanks a lot

like image 688
user3197506 Avatar asked Dec 18 '17 06:12

user3197506


1 Answers

I had same issue when i was using angular 5. I put "name" attribute into my tags and it fixed.

Like:

<input type="text" [(ngModel)]="user.userName"  name="loginUserName" >
like image 135
Wahap Avatar answered Oct 04 '22 17:10

Wahap