Formatting Input Field

Hi,

Is there any ‘Wappler Way’ to implement an input formatter?
I only can find validation rules, which not force users when inputting data.
I would like to achieve something like cleave.js, which directly formats the user input from UI.

Or any reference to applying an external js library?

Regards

You could use the validate -> pattern option using regular expressions.

https://html.com/attributes/input-pattern/

noted… let me try

Seems like the input pattern doesn’t force user input to the specific type.
I’m looking for a solution like Cleave.js example when user input other than number will not show anything.

Can’t you use cleave then? If it’s exactly what you want

Can’t find a tutorial on how to implement the external npm library to Wappler.
I only have little to nothing programming experience.

Can you include the external libs and hand-finish based on the examples. Looks very lightweight

Based on example I need to create js file for the input rules, and call the library using jsDeliver.
I tried to put the JS file inside public/js folder, and mention js file from head area.

It throw me an error 404 not found file.
Do you know where I should create the js file?

Here’s an example I use (e-signature lib) and the location and my URL…path (my calling .ejs file is in a sub-directory of root/

it works! Thank you…

Cool. Well done