title: How to properly use PayloadAction with meta type in redux-toolkit?
body: <p>Simplified example</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>import { createSlice, PayloadAction } from '@reduxjs/toolkit';
  
      type Cake = {
        flavor: string;
        size: 'S' | 'M' | 'L';
      };
  
  const initialState: { all: Cake[]; meta: { currentPage: number } } = {
    all: [],
    meta: {
      currentPage: 0,
    },
  };
  
  const cakeSlice = createSlice({
    name: 'cake',
    initialState,
    reducers: {
      fetchAll(
        state,
        action: PayloadAction&lt;Cake[], string, { currentPage: number }&gt;,
      ) {
        state.all = action.payload;
        state.meta = action.meta;
      },
    },
  });
  
  export default cakeSlice;</code></pre>
  </div>
  </div>
  </p>
  
  <p>I am getting these errors.</p>
  
  <pre><code>Type '
  (state: {
      all: {
          flavor: string;size: "S" | "M" | "L";
      } [];meta: {
          currentPage: number;
      };
  }, action: PayloadAction &lt; Cake[], string, {
      currentPage: number;
  }, never &gt; ) =&gt; void ' is not assignable to type '
  CaseReducer &lt; {
      all: Cake[];meta: {
          currentPage: number;
      };
  }, {
      payload: any;type: string;
  } &gt; | CaseReducerWithPrepare &lt; {
      all: Cake[];meta: {
          currentPage: number;
      };
  }, {
      payload: any;type: string;
  } &gt; '
  </code></pre>
  
  <pre><code>Type '
  (state: {
      all: {
          flavor: string;size: "S" | "M" | "L";
      } [];meta: {
          currentPage: number;
      };
  }, action: PayloadAction &lt; Cake[], string, {
      currentPage: number;
  }, never &gt; ) =&gt; void '
  is not assignable to type 'CaseReducer&lt;{ all: Cake[]; meta: { currentPage: number; }; }, { payload: any; type: string; }&gt;'.
  Types of parameters 'action'
  and 'action'
  are incompatible.
  Type '{ payload: any; type: string; }'
  is not assignable to type 'PayloadAction&lt;Cake[], string, { currentPage: number; }, never&gt;'.
  Property 'meta'
  is missing in type '{ payload: any; type: string; }'
  but required in type '{ meta: { currentPage: number; }; }
  '.
  </code></pre>