I found this p tag in a project I'm working on. This serves as an input field in my front end. I'm not that familiar p tag's being an input field, but I'd just to have the textfocus automatically in this p tag input field when my components loads, so a user is always ready to type and knows where to type.
<div className="create-post">
<p
contentEditable={!this.props.isLoading}
spellCheck="true"
placeholder="Write a new post here"
id="txtContent"
onKeyUp={this.entSub}
onDrop={this.dropDrag}
></p>
</div>
I tried just adding autoFocus as prop to the P tag, but nothing happens. I guess that works only in the real HTML input field.