import { Controller } from "@hotwired/stimulus"

// Connects to data-controller="autosubmit"
export default class extends Controller {
  connect() {
    this.element.addEventListener('change', event => event.target.form.requestSubmit());
  }
}
