pattern attribute in the lightning-input tag can be used o restrict users to avoid entering characters other than alphabets and number in Salesforce Lightning Web Component. Regular Expression should be used. In the following example, I have allowed alphabets and numbers alone.
How to restrict users to avoid entering characters other than alphabets and number in Salesforce Lightning Web Component?
