Do not enter in submit() function

Keywords: javascript php jquery html

Question: 

I'm trying to do a function that sends the form via AJAX, but does not enter the .submit function of the form. what am I doing wrong?

That's my function JQuery in file script.js

$(document).ready(function(){
    debugger;
    console.log('doc'); // Enter here!
    $('#formClient').submit(function(){
        console.log('submit'); // Not enter here!
        // var dados = jQuery( this ).serialize();
        // $.ajax({
        //     type: 'POST',
        //     url: '../client/clientRegisterEdit.php',
        //     data: dados,
        //     success: function(data){
        //         alert(data);
        //     }
        // });
        // return false;
    });
});

That's my form HTML

    <form action="<?php //echo urlClientRegisterEdit ?> " method="post" id="formClient" name="formClient"  onsubmit="">
       <div class="row">
          <div class="col-12 col-sm-12 col-md-12 col-lg-12">
             <button type="submit" class="btn btn-success">
                <i class="fa fa-save"></i> Salvar
             </button>       
          </div>
      </div>
      <div class="row">
          <div class="col-12 col-sm-12 col-md-12 col-lg-3">
              <div class="form-group">
                 <label for="">Código:</label>
                 <input type="text" class="form-control" name="code" id="code" aria-describedby="helpId" placeholder="">
                 <!-- Others inputs here-->
             </div>
         </div>
      </div>
  </form>

Answers: