@h3ravel/support 2.2.3 → 2.2.5

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.
package/dist/index.d.ts CHANGED
@@ -692,7 +692,7 @@ declare class Arr {
692
692
  * Arr.divide(['a','b']) -> [[0,1], ['a','b']]
693
693
  * Arr.divide({x:1,y:2}) -> [['x','y'], [1,2]]
694
694
  */
695
- static divide<A>(input: A[] | Record<string, A>): (number[] | A[])[] | (A[] | string[])[];
695
+ static divide<A>(input: A[] | Record<string, A>): (number[] | A[])[] | (string[] | A[])[];
696
696
  /**
697
697
  * Flatten a nested array/object structure into a single-level object
698
698
  * with dot-notated keys.
@@ -3534,7 +3534,7 @@ declare abstract class ServiceProvider extends IServiceProvider {
3534
3534
  */
3535
3535
  declare class AssetsServiceProvider extends ServiceProvider {
3536
3536
  static priority: number;
3537
- register(): void;
3537
+ register(): Promise<void>;
3538
3538
  }
3539
3539
  //#endregion
3540
3540
  //#region src/Providers/RouteServiceProvider.d.ts
package/dist/index.js CHANGED
@@ -10,7 +10,6 @@ import { Logger, trait } from "@h3ravel/shared";
10
10
  import { readFile, stat } from "node:fs/promises";
11
11
  import { IRouter, IServiceProvider } from "@h3ravel/contracts";
12
12
  import { join } from "node:path";
13
- import { serveStatic } from "h3";
14
13
  import { statSync } from "node:fs";
15
14
  //#region src/Collection.ts
16
15
  var Collection = class extends Collection$1 {
@@ -6536,7 +6535,8 @@ var ServiceProvider = class extends IServiceProvider {
6536
6535
  */
6537
6536
  var AssetsServiceProvider = class extends ServiceProvider {
6538
6537
  static priority = 996;
6539
- register() {
6538
+ async register() {
6539
+ const { serveStatic } = await import("h3");
6540
6540
  const app = this.app.make("router");
6541
6541
  const publicPath = this.app.getPath("public");
6542
6542
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@h3ravel/support",
3
- "version": "2.2.3",
3
+ "version": "2.2.5",
4
4
  "description": "Shared helpers, facades and utilities for H3ravel.",
5
5
  "type": "module",
6
6
  "types": "./dist/index.d.ts",
@@ -36,13 +36,21 @@
36
36
  "@types/luxon": "^3.7.1",
37
37
  "typescript": "^6.0.0"
38
38
  },
39
+ "peerDependencies": {
40
+ "h3": "^2.0.1-rc.22"
41
+ },
39
42
  "dependencies": {
40
- "@h3ravel/shared": "^2.2.3",
43
+ "@h3ravel/shared": "^2.2.5",
41
44
  "@h3ravel/collect.js": "^5.4.0",
42
- "@h3ravel/contracts": "^2.2.3",
45
+ "@h3ravel/contracts": "^2.2.5",
43
46
  "dayjs": "^1.11.18",
44
47
  "luxon": "^3.7.2"
45
48
  },
49
+ "peerDependenciesMeta": {
50
+ "h3": {
51
+ "optional": true
52
+ }
53
+ },
46
54
  "scripts": {
47
55
  "build": "tsdown --config-loader unrun",
48
56
  "dev": "tsdown --watch --config-loader unrun",