@inversifyjs/http-better-auth 2.0.0

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.
Files changed (134) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/LICENSE +21 -0
  3. package/README.md +6 -0
  4. package/lib/cjs/auth/calculations/buildBetterAuthExpress4Controller.d.ts +3 -0
  5. package/lib/cjs/auth/calculations/buildBetterAuthExpress4Controller.d.ts.map +1 -0
  6. package/lib/cjs/auth/calculations/buildBetterAuthExpress4Controller.js +34 -0
  7. package/lib/cjs/auth/calculations/buildBetterAuthExpress4Controller.js.map +1 -0
  8. package/lib/cjs/auth/calculations/buildBetterAuthExpressController.d.ts +3 -0
  9. package/lib/cjs/auth/calculations/buildBetterAuthExpressController.d.ts.map +1 -0
  10. package/lib/cjs/auth/calculations/buildBetterAuthExpressController.js +34 -0
  11. package/lib/cjs/auth/calculations/buildBetterAuthExpressController.js.map +1 -0
  12. package/lib/cjs/auth/calculations/buildBetterAuthFastifyController.d.ts +3 -0
  13. package/lib/cjs/auth/calculations/buildBetterAuthFastifyController.d.ts.map +1 -0
  14. package/lib/cjs/auth/calculations/buildBetterAuthFastifyController.js +86 -0
  15. package/lib/cjs/auth/calculations/buildBetterAuthFastifyController.js.map +1 -0
  16. package/lib/cjs/auth/calculations/buildBetterAuthHonoController.d.ts +3 -0
  17. package/lib/cjs/auth/calculations/buildBetterAuthHonoController.d.ts.map +1 -0
  18. package/lib/cjs/auth/calculations/buildBetterAuthHonoController.js +32 -0
  19. package/lib/cjs/auth/calculations/buildBetterAuthHonoController.js.map +1 -0
  20. package/lib/cjs/auth/calculations/buildBetterAuthMiddleware.d.ts +6 -0
  21. package/lib/cjs/auth/calculations/buildBetterAuthMiddleware.d.ts.map +1 -0
  22. package/lib/cjs/auth/calculations/buildBetterAuthMiddleware.js +13 -0
  23. package/lib/cjs/auth/calculations/buildBetterAuthMiddleware.js.map +1 -0
  24. package/lib/cjs/auth/calculations/buildUserSessionFromExpressRequest.d.ts +5 -0
  25. package/lib/cjs/auth/calculations/buildUserSessionFromExpressRequest.d.ts.map +1 -0
  26. package/lib/cjs/auth/calculations/buildUserSessionFromExpressRequest.js +13 -0
  27. package/lib/cjs/auth/calculations/buildUserSessionFromExpressRequest.js.map +1 -0
  28. package/lib/cjs/auth/calculations/buildUserSessionFromExpressRequest.spec.d.ts +2 -0
  29. package/lib/cjs/auth/calculations/buildUserSessionFromExpressRequest.spec.d.ts.map +1 -0
  30. package/lib/cjs/auth/calculations/buildUserSessionFromFastifyRequest.d.ts +5 -0
  31. package/lib/cjs/auth/calculations/buildUserSessionFromFastifyRequest.d.ts.map +1 -0
  32. package/lib/cjs/auth/calculations/buildUserSessionFromFastifyRequest.js +13 -0
  33. package/lib/cjs/auth/calculations/buildUserSessionFromFastifyRequest.js.map +1 -0
  34. package/lib/cjs/auth/calculations/buildUserSessionFromFastifyRequest.spec.d.ts +2 -0
  35. package/lib/cjs/auth/calculations/buildUserSessionFromFastifyRequest.spec.d.ts.map +1 -0
  36. package/lib/cjs/auth/calculations/buildUserSessionFromHonoRequest.d.ts +5 -0
  37. package/lib/cjs/auth/calculations/buildUserSessionFromHonoRequest.d.ts.map +1 -0
  38. package/lib/cjs/auth/calculations/buildUserSessionFromHonoRequest.js +14 -0
  39. package/lib/cjs/auth/calculations/buildUserSessionFromHonoRequest.js.map +1 -0
  40. package/lib/cjs/auth/calculations/buildUserSessionFromHonoRequest.spec.d.ts +2 -0
  41. package/lib/cjs/auth/calculations/buildUserSessionFromHonoRequest.spec.d.ts.map +1 -0
  42. package/lib/cjs/auth/calculations/getBetterAuthFromRequest.d.ts +4 -0
  43. package/lib/cjs/auth/calculations/getBetterAuthFromRequest.d.ts.map +1 -0
  44. package/lib/cjs/auth/calculations/getBetterAuthFromRequest.js +13 -0
  45. package/lib/cjs/auth/calculations/getBetterAuthFromRequest.js.map +1 -0
  46. package/lib/cjs/auth/calculations/getBetterAuthFromRequest.spec.d.ts +2 -0
  47. package/lib/cjs/auth/calculations/getBetterAuthFromRequest.spec.d.ts.map +1 -0
  48. package/lib/cjs/auth/decorators/ExpressUserSession.d.ts +2 -0
  49. package/lib/cjs/auth/decorators/ExpressUserSession.d.ts.map +1 -0
  50. package/lib/cjs/auth/decorators/ExpressUserSession.int.spec.d.ts +2 -0
  51. package/lib/cjs/auth/decorators/ExpressUserSession.int.spec.d.ts.map +1 -0
  52. package/lib/cjs/auth/decorators/ExpressUserSession.js +10 -0
  53. package/lib/cjs/auth/decorators/ExpressUserSession.js.map +1 -0
  54. package/lib/cjs/auth/decorators/ExpressUserSession.spec.d.ts +2 -0
  55. package/lib/cjs/auth/decorators/ExpressUserSession.spec.d.ts.map +1 -0
  56. package/lib/cjs/auth/decorators/FastifyUserSession.d.ts +2 -0
  57. package/lib/cjs/auth/decorators/FastifyUserSession.d.ts.map +1 -0
  58. package/lib/cjs/auth/decorators/FastifyUserSession.int.spec.d.ts +2 -0
  59. package/lib/cjs/auth/decorators/FastifyUserSession.int.spec.d.ts.map +1 -0
  60. package/lib/cjs/auth/decorators/FastifyUserSession.js +10 -0
  61. package/lib/cjs/auth/decorators/FastifyUserSession.js.map +1 -0
  62. package/lib/cjs/auth/decorators/FastifyUserSession.spec.d.ts +2 -0
  63. package/lib/cjs/auth/decorators/FastifyUserSession.spec.d.ts.map +1 -0
  64. package/lib/cjs/auth/decorators/HonoUserSession.d.ts +2 -0
  65. package/lib/cjs/auth/decorators/HonoUserSession.d.ts.map +1 -0
  66. package/lib/cjs/auth/decorators/HonoUserSession.int.spec.d.ts +2 -0
  67. package/lib/cjs/auth/decorators/HonoUserSession.int.spec.d.ts.map +1 -0
  68. package/lib/cjs/auth/decorators/HonoUserSession.js +10 -0
  69. package/lib/cjs/auth/decorators/HonoUserSession.js.map +1 -0
  70. package/lib/cjs/auth/decorators/HonoUserSession.spec.d.ts +2 -0
  71. package/lib/cjs/auth/decorators/HonoUserSession.spec.d.ts.map +1 -0
  72. package/lib/cjs/auth/models/BetterAuth.d.ts +3 -0
  73. package/lib/cjs/auth/models/BetterAuth.d.ts.map +1 -0
  74. package/lib/cjs/auth/models/BetterAuth.js +3 -0
  75. package/lib/cjs/auth/models/BetterAuth.js.map +1 -0
  76. package/lib/cjs/auth/models/UserSession.d.ts +6 -0
  77. package/lib/cjs/auth/models/UserSession.d.ts.map +1 -0
  78. package/lib/cjs/auth/models/UserSession.js +3 -0
  79. package/lib/cjs/auth/models/UserSession.js.map +1 -0
  80. package/lib/cjs/auth/models/betterAuthControllerServiceIdentifier.d.ts +2 -0
  81. package/lib/cjs/auth/models/betterAuthControllerServiceIdentifier.d.ts.map +1 -0
  82. package/lib/cjs/auth/models/betterAuthControllerServiceIdentifier.js +5 -0
  83. package/lib/cjs/auth/models/betterAuthControllerServiceIdentifier.js.map +1 -0
  84. package/lib/cjs/auth/models/betterAuthMiddlewareServiceIdentifier.d.ts +2 -0
  85. package/lib/cjs/auth/models/betterAuthMiddlewareServiceIdentifier.d.ts.map +1 -0
  86. package/lib/cjs/auth/models/betterAuthMiddlewareServiceIdentifier.js +5 -0
  87. package/lib/cjs/auth/models/betterAuthMiddlewareServiceIdentifier.js.map +1 -0
  88. package/lib/cjs/auth/models/betterAuthProperty.d.ts +2 -0
  89. package/lib/cjs/auth/models/betterAuthProperty.d.ts.map +1 -0
  90. package/lib/cjs/auth/models/betterAuthProperty.js +5 -0
  91. package/lib/cjs/auth/models/betterAuthProperty.js.map +1 -0
  92. package/lib/cjs/auth/models/betterAuthServiceIdentifier.d.ts +2 -0
  93. package/lib/cjs/auth/models/betterAuthServiceIdentifier.d.ts.map +1 -0
  94. package/lib/cjs/auth/models/betterAuthServiceIdentifier.js +5 -0
  95. package/lib/cjs/auth/models/betterAuthServiceIdentifier.js.map +1 -0
  96. package/lib/cjs/auth/services/BaseBetterAuthContainerModule.d.ts +13 -0
  97. package/lib/cjs/auth/services/BaseBetterAuthContainerModule.d.ts.map +1 -0
  98. package/lib/cjs/auth/services/BaseBetterAuthContainerModule.js +31 -0
  99. package/lib/cjs/auth/services/BaseBetterAuthContainerModule.js.map +1 -0
  100. package/lib/cjs/auth/services/BetterAuthExpress4ContainerModule.d.ts +9 -0
  101. package/lib/cjs/auth/services/BetterAuthExpress4ContainerModule.d.ts.map +1 -0
  102. package/lib/cjs/auth/services/BetterAuthExpress4ContainerModule.int.spec.d.ts +2 -0
  103. package/lib/cjs/auth/services/BetterAuthExpress4ContainerModule.int.spec.d.ts.map +1 -0
  104. package/lib/cjs/auth/services/BetterAuthExpress4ContainerModule.js +15 -0
  105. package/lib/cjs/auth/services/BetterAuthExpress4ContainerModule.js.map +1 -0
  106. package/lib/cjs/auth/services/BetterAuthExpressContainerModule.d.ts +9 -0
  107. package/lib/cjs/auth/services/BetterAuthExpressContainerModule.d.ts.map +1 -0
  108. package/lib/cjs/auth/services/BetterAuthExpressContainerModule.int.spec.d.ts +2 -0
  109. package/lib/cjs/auth/services/BetterAuthExpressContainerModule.int.spec.d.ts.map +1 -0
  110. package/lib/cjs/auth/services/BetterAuthExpressContainerModule.js +15 -0
  111. package/lib/cjs/auth/services/BetterAuthExpressContainerModule.js.map +1 -0
  112. package/lib/cjs/auth/services/BetterAuthFastifyContainerModule.d.ts +9 -0
  113. package/lib/cjs/auth/services/BetterAuthFastifyContainerModule.d.ts.map +1 -0
  114. package/lib/cjs/auth/services/BetterAuthFastifyContainerModule.int.spec.d.ts +2 -0
  115. package/lib/cjs/auth/services/BetterAuthFastifyContainerModule.int.spec.d.ts.map +1 -0
  116. package/lib/cjs/auth/services/BetterAuthFastifyContainerModule.js +15 -0
  117. package/lib/cjs/auth/services/BetterAuthFastifyContainerModule.js.map +1 -0
  118. package/lib/cjs/auth/services/BetterAuthHonoContainerModule.d.ts +9 -0
  119. package/lib/cjs/auth/services/BetterAuthHonoContainerModule.d.ts.map +1 -0
  120. package/lib/cjs/auth/services/BetterAuthHonoContainerModule.int.spec.d.ts +2 -0
  121. package/lib/cjs/auth/services/BetterAuthHonoContainerModule.int.spec.d.ts.map +1 -0
  122. package/lib/cjs/auth/services/BetterAuthHonoContainerModule.js +15 -0
  123. package/lib/cjs/auth/services/BetterAuthHonoContainerModule.js.map +1 -0
  124. package/lib/cjs/index.d.ts +11 -0
  125. package/lib/cjs/index.d.ts.map +1 -0
  126. package/lib/cjs/index.js +20 -0
  127. package/lib/cjs/index.js.map +1 -0
  128. package/lib/cjs/package.json +3 -0
  129. package/lib/esm/index.d.ts +49 -0
  130. package/lib/esm/index.d.ts.map +1 -0
  131. package/lib/esm/index.js +2 -0
  132. package/lib/esm/index.js.map +1 -0
  133. package/lib/esm/package.json +3 -0
  134. package/package.json +88 -0
package/package.json ADDED
@@ -0,0 +1,88 @@
1
+ {
2
+ "author": "Roberto Pintos López",
3
+ "bugs": {
4
+ "url": "https://github.com/inversify/monorepo/issues"
5
+ },
6
+ "description": "InversifyJs http Better Auth package",
7
+ "dependencies": {
8
+ "@inversifyjs/http-core": "2.0.0"
9
+ },
10
+ "devDependencies": {
11
+ "@hono/node-server": "1.19.4",
12
+ "@stryker-mutator/core": "9.1.1",
13
+ "@stryker-mutator/typescript-checker": "9.1.1",
14
+ "@stryker-mutator/vitest-runner": "9.1.1",
15
+ "@types/better-sqlite3": "^7.6.13",
16
+ "@types/express": "5.0.3",
17
+ "@types/express4": "npm:@types/express@4.17.23",
18
+ "@types/node": "22.18.6",
19
+ "@vitest/coverage-v8": "3.2.4",
20
+ "better-sqlite3": "^12.3.0",
21
+ "eslint": "9.36.0",
22
+ "fastify": "5.6.1",
23
+ "hono": "4.9.8",
24
+ "prettier": "3.6.2",
25
+ "rimraf": "6.0.1",
26
+ "rollup": "4.52.0",
27
+ "ts-loader": "9.5.4",
28
+ "tslib": "2.8.1",
29
+ "typescript": "5.9.2",
30
+ "vitest": "3.2.4",
31
+ "@inversifyjs/http-express": "2.0.0",
32
+ "@inversifyjs/http-express-v4": "2.0.0",
33
+ "@inversifyjs/http-fastify": "2.0.0",
34
+ "@inversifyjs/http-hono": "2.0.0"
35
+ },
36
+ "devEngines": {
37
+ "node": "^22.10.2",
38
+ "pnpm": "^10.13.1"
39
+ },
40
+ "homepage": "https://inversify.io",
41
+ "keywords": [
42
+ "dependency injection",
43
+ "dependency inversion",
44
+ "di",
45
+ "inversion of control container",
46
+ "ioc",
47
+ "javascript",
48
+ "node",
49
+ "typescript"
50
+ ],
51
+ "license": "MIT",
52
+ "main": "lib/cjs/index.js",
53
+ "module": "lib/esm/index.js",
54
+ "exports": {
55
+ ".": {
56
+ "import": "./lib/esm/index.js",
57
+ "require": "./lib/cjs/index.js"
58
+ }
59
+ },
60
+ "name": "@inversifyjs/http-better-auth",
61
+ "peerDependencies": {
62
+ "better-auth": "^1.3.13",
63
+ "inversify": "^7.10.0"
64
+ },
65
+ "publishConfig": {
66
+ "access": "public"
67
+ },
68
+ "repository": {
69
+ "type": "git",
70
+ "url": "git+https://github.com/inversify/monorepo.git"
71
+ },
72
+ "version": "2.0.0",
73
+ "scripts": {
74
+ "build": "pnpm run build:cjs && pnpm run build:esm",
75
+ "build:cjs": "tsc --build tsconfig.cjs.json && pnpm exec foundation-ts-package-cjs ./lib/cjs",
76
+ "build:esm": "rollup -c ./rollup.config.mjs && pnpm exec foundation-ts-package-esm ./lib/esm",
77
+ "build:clean": "rimraf lib",
78
+ "format": "prettier --write ./src",
79
+ "lint": "eslint ./src",
80
+ "prebuild": "pnpm run build:clean",
81
+ "test": "vitest run",
82
+ "test:integration": "pnpm run test --project Integration",
83
+ "test:coverage": "pnpm run test:unit --coverage",
84
+ "test:mutation": "stryker run",
85
+ "test:uncommitted": "pnpm run test --changed=HEAD",
86
+ "test:unit": "pnpm run test --project Unit"
87
+ }
88
+ }