inertia icon indicating copy to clipboard operation
inertia copied to clipboard

fix: invalid type declaration for RequestPayload

Open Tofandel opened this issue 3 years ago • 2 comments

Before this fix, any nesting of objects as a request payload would throw a typescript error

Eg: the following code would throw a type error, even though it's a perfectly safe formDataConvertible

Inertia.patch('', {
      files: {
        test: {
          uploaded_files: [
            1, 2, 3
          ],
       },
    },
});

This aims to fix this problem

Tofandel avatar Jun 10 '22 09:06 Tofandel

@Tofandel Would you mind resolving the merge conflicts on this PR please?

@reinink Would it be possible to please get this merged in after the conflicts have been resolved?

This fix should hopefully resolve some open issues (ones that are currently also affecting my team and I, hence my interest):

  • https://github.com/inertiajs/inertia/issues/1193
  • https://github.com/inertiajs/inertia/issues/945

NattieGit avatar Jul 22 '22 13:07 NattieGit

@nyatalieee Sure, conflict resolved

Tofandel avatar Jul 22 '22 13:07 Tofandel

Hey! Thanks so much for your interest in Inertia.js and for submitting this contribution.

In an attempt to get on top of the issues and pull requests on this project I am going through all the older issues and PRs and closing them, as there's a decent chance that they have since been resolved or are simply not relevant any longer. My hope is that with a "clean slate" me and the other project maintainers will be able to better keep on top of issues and PRs moving forward.

Of course there's a chance that this PR is still relevant, and if that's the case feel free to re-submit it. If it's a new feature and not a bug fix maybe respond here first to make sure that it's something we want to include in the library.

Really not trying to be dismissive here, I just need to find a way to get this project back into a state that I am able to maintain it. Hope that makes sense! ❤️

reinink avatar Jul 28 '23 02:07 reinink