This project is not covered by Drupal’s security advisory policy.
You can display the "You have unsaved changes" warning on a form when any input has been changed.

Just attach the defined library to your form.
/**
* Implements hook_form_alter().
*/
function YOURMODULE_form_alter(&$form, FormStateInterface $form_state, $form_id) {
$form['#attached']['library'][] = 'form_change_warning/form_change_warning';
}
Similar modules
| Attachment | Size |
|---|---|
| Screenshot 2025-01-10 at 17.07.36.png | 54.5 KB |
Project information
Minimally maintained
Maintainers monitor issues, but fast responses are not guaranteed.Maintenance fixes only
Considered feature-complete by its maintainers.- Project categories: Content editing experience
4 sites report using this module
- Created by tikaszvince on , updated
This project is not covered by the security advisory policy.
Use at your own risk! It may have publicly disclosed vulnerabilities.
Releases
1.0.0-alpha1
released 10 January 2025
Works with Drupal: ^10.3 || ^11.0
Install:
Development version: 1.0.x-dev updated 10 Jan 2025 at 16:14 UTC
