Ask a Question
Ask Question Login
Corporate Training
  1. Community
  2. Salesforce
  3. Question
Salesforce

How to fetch content on onpaste events in LWC?

Asked by Carol Bower Jul 23, 2021 1.4K views 1 answer
Share

About this question

When I am trying to fetch the data on onpaste event. checkPasteLength gets invoked when I try to paste some text but event.key returns undefined and event.clipboardData.getData('textarea') returns null

checkPasteLength(event){ console.log(event.key); console.log(event.clipboardData.getData('textarea')); }

Is there a way to get the value on onpaste


Your answer

1 Answer

More Salesforce discussions

Learn & Explore

Free tutorials and interview questions from industry experts — learn the skill, then get ready to prove it.

Latest Salesforce Blogs

Guides, tips and career advice on Salesforce from JanBask experts.