question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

cy.type() can only be called on textarea or text:

See original GitHub issue

Hey all. At first, sorry for my english, its bad need to type text in the form. How to do this not only with the cy.type command. Is it possible?

Ubuntu 16.04 cypress version 2.1.0 selection_002

/code cy.get(‘.textField_question-0-155’).type(‘sad’) /code `` selection_001 What is problem? Thanks

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:2
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

8reactions
kucebcommented, Mar 22, 2018

Use Cypress to select the div with contenteditable="true". For example: cy.get('[contenteditable]').type('some text") In your case, use find to select something inside another selector:

cy.get('.textField_question-0-155').find('[contenteditable]').type('some text')
1reaction
jennifer-shehanecommented, Mar 20, 2018

Related proposal to turn off validation checking with type: https://github.com/cypress-io/cypress/issues/586

Read more comments on GitHub >

github_iconTop Results From Across the Web

type - Cypress Documentation
The text to be typed into the DOM element. Text passed to .type() may include any of the special character sequences below. These...
Read more >
Cypress error. cy.type() failed because it requires a valid ...
How to type text by cypress cy.type in <ion-input> Input type? ... How to address Cypress (cy.type() can only be called on a...
Read more >
Solve Flake In Cypress Typing Into An Input Element
The cy. type command simply waits for the input element to be enabled (it is a built-in actionability check) before typing. You can...
Read more >
cy.type() failed because it targeted a disabled element
This error should never occur without a valid reason. We have analyzed the tests and made sure that the element is ready for...
Read more >
cypress-io/cypress - Gitter
error = CypressError: cy.type() can only be called on a single element. Your subject contained 16 elements. thanks @k.vinodmathew_gitlab hope you can help ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found