Storing uploaded file in state variable wont work. React

I am trying to store an uploaded file in a state variable that I will post to the DB once the user has completed the rest of the form. For some reason, my state wont update and my state variable is left null. I am calling onChange and passing it my onChange function to store the file in state. I put some comments in the code. Can anyone help please?

interface PostState {
  file: File
  //i have tried multiple data types for the file variable, still no luck
}

const Form = (props) => {

  const defaultPostState: PostState = {
    file: null,
    //i have also tried setting this to undefined or not setting a default value at all as well
  }

const [postState, setPostState] = useState(defaultPostState)

const onChange = (e) => {
  setPostState({...postState, file: e.target.files[0]})
  //this is what wont work - i have debugged it and logged it, it wont store the target file in file
}

<div className='form-group'>
  <label>Upload file</label>
  <input
    id='file'
    className='form-control-file'
    type='file'
    name='file'
    ref={register}
    onChange={onChange} 
  />
</div>