Hi, great add-on. I have used Cleave.js in other Angular projects, first ti

Hi, great add-on.
I have used Cleave.js in other Angular projects, first time in Vaadin.

I added dependency to my pom.xml, everything looks normal, compiles and run, except formatter does not work. I looked into node-modules directory and did not find cleave.js. I suppose cleave did not installed automatically.
Using
Vaadin 4.1.3 over Springboot
org.vaadin.textfieldformatter v.4.1.4

I ran npm install, and mvn vaadin:prepare-frontend but no progress.
I am new to Vaadin. What may be the cause?

Could you delete node_modules and package-lock.json in the project folder and update to 14.1.17. Try again by just running mvn spring-boot:run

I was able to reproduce this behavior with a fresh project.

  1. created a default Vaadin 14.1.17 Spring Boot app
  2. Added the add-on dependency
  3. Debug as Java Application.

Npm install is run, but cleave.js is not imported.

I deleted node_modules and package-lock.json and tried again with mvn spring-boot:run from command line and now cleave.js is in node_modules. Strange.

Hi Johannes.

I have solved problem with mvn vaadin:prepare-frontend vaadin:build-frontend

Thank you.

By the way, do you have any plans on extending TextFieldFormatter for DatePicker and TimePicker? It would be great if user could just type date in DatePicker without typing dots or slashes.

I can try if the add-on works with those fields. It might be that DatePicker or TimePicker will not like an extension messing with the text input. Btw. at least I can port the DateFieldFormatter from the Vaadin 8 version. That works for TextFields.

4.4.0 has now DateFieldFormatter for TextFields. I’ll try if it works for DatePicker.

Does not seem to work. I’m sorry, but that feature should be implemented into DatePicker.