Skip to content

[Question]How to enter text in div tag in playwright test tool? #2297

@maheshpatnam

Description

@maheshpatnam

I am getting error( Error: Element is not an , <textarea> or [contenteditable] element.) when i try to enter text in div tag
Here is code.

await page.mainFrame().waitForSelector(sendMesssageBoxSelector);
const sendMessageBox = await page.$(sendMesssageBoxSelector);
await sendMessageBox.click();
await sendMessageBox.fill('hello');

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions