title: Convert files form input to arr and remove file
body: <p>I decided to  create one more validation, this time in user side (java-script).</p>
  <p>I would like to do it in simple way. I decided to convert inputs files to the array, and then remove file.</p>
  <p>my code</p>
  <pre class="lang-java prettyprint-override"><code>    let uploadField = document.getElementById(&quot;file&quot;); //mój input
  
         uploadField.addEventListener('change', checkFileSize)
  
      
        
         function checkFileSize() {
  
             let amount_files = uploadField.files.length;
             
             let files_array = Array.from(uploadField.files);
         
  
             let maxsize = 3*1024*1024;
  
             console.log(Array.isArray(files_array));
            
             for(let i = 0; i &lt; amount_files; i++) {
  
                if(files_array[i] &gt;  maxsize) {
                 files_array.splice(i, 1);
                 
                 
                }
                
             }
             console.log(files_array);
         }    
  </code></pre>
  <p>I think that on this line</p>
  <p>if(files_array[i] &gt;  maxsize</p>
  <p>I should put  file size after &quot;if&quot; , but I don't know how to get it (i saw this property on console)</p>