@adonisjs/inertia 4.0.0-next.6 → 4.0.0-next.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8,13 +8,18 @@ var TYPES_EXTRACTION_HELPER = {
8
8
  vue3: `import type { VNodeProps, AllowedComponentProps, ComponentInstance } from 'vue'
9
9
 
10
10
  type ExtractProps<T> = Omit<
11
- ComponentInstance<T>['$props'][K],
11
+ ComponentInstance<T>['$props'],
12
12
  keyof VNodeProps | keyof AllowedComponentProps
13
13
  >`,
14
14
  react: `import type React from 'react'
15
+ import type { Prettify } from '@adonisjs/core/types/common'
15
16
 
16
17
  type ExtractProps<T> =
17
- T extends React.FC<infer Props> ? Props : T extends React.Component<infer Props> ? Props : never`
18
+ T extends React.FC<infer Props>
19
+ ? Prettify<Omit<Props, 'children'>>
20
+ : T extends React.Component<infer Props>
21
+ ? Prettify<Omit<Props, 'children'>>
22
+ : never`
18
23
  };
19
24
  var indexPages = function(config) {
20
25
  if (!SUPPORTED_FRAMEWORKS.includes(config.framework)) {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  defineConfig
3
- } from "../chunk-N5YXFHD2.js";
3
+ } from "../chunk-5QRJHXXQ.js";
4
4
  import {
5
5
  Inertia,
6
6
  ServerRenderer
package/build/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  defineConfig,
3
3
  indexPages
4
- } from "./chunk-N5YXFHD2.js";
4
+ } from "./chunk-5QRJHXXQ.js";
5
5
  import {
6
6
  Inertia,
7
7
  InertiaManager,
@@ -1,6 +1,6 @@
1
1
  import { type Route } from '@adonisjs/core/http';
2
2
  import type { ApplicationService } from '@adonisjs/core/types';
3
- import type { AsPageProps, InertiaPages } from '../src/types.js';
3
+ import type { AsPageProps, ComponentProps, InertiaPages, SharedProps } from '../src/types.js';
4
4
  declare module '@adonisjs/core/http' {
5
5
  interface BriskRoute {
6
6
  /**
@@ -29,7 +29,7 @@ declare module '@adonisjs/core/http' {
29
29
  * })
30
30
  * ```
31
31
  */
32
- renderInertia<Page extends keyof InertiaPages>(component: Page, props: AsPageProps<InertiaPages[Page]>, viewProps?: Record<string, any>): Route;
32
+ renderInertia<Page extends keyof InertiaPages>(component: Page, props: InertiaPages[Page] extends ComponentProps ? AsPageProps<Omit<InertiaPages[Page], keyof SharedProps>> : never, viewProps?: Record<string, any>): Route;
33
33
  }
34
34
  }
35
35
  /**
@@ -1,4 +1,4 @@
1
- import { type AsyncOrSync } from '@poppinss/utils/types';
1
+ import { type AsyncOrSync } from '@adonisjs/core/types/common';
2
2
  import { type DeferProp, type PageProps, type AlwaysProp, type OptionalProp, type MergeableProp, type ComponentProps, type UnPackedPageProps } from './types.ts';
3
3
  import { type ContainerResolver } from '@adonisjs/core/container';
4
4
  /**
@@ -1,7 +1,7 @@
1
1
  import type { HttpContext } from '@adonisjs/core/http';
2
2
  import { type ContainerResolver } from '@adonisjs/core/container';
3
3
  import type { JSONDataTypes } from '@adonisjs/core/types/transformers';
4
- import type { AsyncOrSync, DeepPartial, Prettify } from '@poppinss/utils/types';
4
+ import type { AsyncOrSync, DeepPartial, Prettify } from '@adonisjs/core/types/common';
5
5
  import { type DEEP_MERGE, type ALWAYS_PROP, type OPTIONAL_PROP, type TO_BE_MERGED, type DEFERRED_PROP } from './symbols.ts';
6
6
  /**
7
7
  * Representation of a resource item, collection and paginator that can be serialized
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@adonisjs/inertia",
3
3
  "description": "Official Inertia.js adapter for AdonisJS",
4
- "version": "4.0.0-next.6",
4
+ "version": "4.0.0-next.8",
5
5
  "engines": {
6
6
  "node": ">=24.0.0"
7
7
  },
@@ -42,13 +42,13 @@
42
42
  "docs": "typedoc"
43
43
  },
44
44
  "devDependencies": {
45
- "@adonisjs/assembler": "^8.0.0-next.9",
46
- "@adonisjs/core": "^7.0.0-next.1",
45
+ "@adonisjs/assembler": "^8.0.0-next.14",
46
+ "@adonisjs/core": "^7.0.0-next.8",
47
47
  "@adonisjs/eslint-config": "^3.0.0-next.4",
48
48
  "@adonisjs/prettier-config": "^1.4.5",
49
49
  "@adonisjs/session": "^8.0.0-next.0",
50
- "@adonisjs/tsconfig": "^2.0.0-next.0",
51
- "@adonisjs/vite": "^5.0.1-next.0",
50
+ "@adonisjs/tsconfig": "^2.0.0-next.3",
51
+ "@adonisjs/vite": "^5.1.0-next.0",
52
52
  "@japa/api-client": "^3.1.0",
53
53
  "@japa/assert": "4.1.1",
54
54
  "@japa/expect-type": "^2.0.3",
@@ -58,21 +58,21 @@
58
58
  "@japa/snapshot": "^2.0.9",
59
59
  "@poppinss/ts-exec": "^1.4.1",
60
60
  "@release-it/conventional-changelog": "^10.0.1",
61
- "@types/node": "^24.6.2",
61
+ "@types/node": "^24.8.1",
62
62
  "@types/supertest": "^6.0.3",
63
63
  "c8": "^10.1.3",
64
64
  "copyfiles": "^2.4.1",
65
65
  "cross-env": "^10.1.0",
66
66
  "del-cli": "^7.0.0",
67
67
  "edge.js": "^6.3.0",
68
- "eslint": "^9.36.0",
68
+ "eslint": "^9.38.0",
69
69
  "get-port": "^7.1.0",
70
70
  "prettier": "^3.6.2",
71
71
  "release-it": "^19.0.5",
72
72
  "supertest": "^7.1.4",
73
73
  "tsup": "^8.5.0",
74
74
  "typescript": "~5.9.3",
75
- "vite": "^7.1.7"
75
+ "vite": "^7.1.10"
76
76
  },
77
77
  "dependencies": {
78
78
  "@poppinss/utils": "^7.0.0-next.3",
@@ -80,10 +80,10 @@
80
80
  "html-entities": "^2.6.0"
81
81
  },
82
82
  "peerDependencies": {
83
- "@adonisjs/assembler": "^8.0.0-next.7",
84
- "@adonisjs/core": "^7.0.0-next.0",
83
+ "@adonisjs/assembler": "^8.0.0-next.14",
84
+ "@adonisjs/core": "^7.0.0-next.6",
85
85
  "@adonisjs/session": "^8.0.0-next.0",
86
- "@adonisjs/vite": "^5.0.1-next.0",
86
+ "@adonisjs/vite": "^5.1.0-next.0",
87
87
  "@japa/api-client": "^3.1.0",
88
88
  "@japa/plugin-adonisjs": "^5.0.0-next.0",
89
89
  "edge.js": "^6.0.0"