@lcas58/esmi-api-types 1.0.4 → 1.0.6

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.
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Shared types and schemas for the ESMI API
3
+ * This file exports all types and Zod schemas that should be shared with the frontend
4
+ */
5
+ // =============================================================================
6
+ // DATABASE SCHEMAS
7
+ // =============================================================================
8
+ export {
9
+ // Organization schemas
10
+ createOrganizationWithDetailsSchema, generateSocialMediaUrl, getOrganizationWithDetailsSchema,
11
+ // Marketing schemas
12
+ insertEmailCampaignSchema,
13
+ // League schemas
14
+ insertLeaguesSchema,
15
+ // Location schemas
16
+ insertLocationSchema, insertOrganizationSchema, insertOrganizationSocialMediaSchema, insertOrganizationTagSchema, insertOrganizationWebsiteSchema, patchOrganizationSchema, selectEmailCampaignSchema,
17
+ // Event schemas
18
+ selectEventSchema, selectLeaguesSchema, selectLocationSchema, selectOrganizationSchema,
19
+ // Pickup schemas
20
+ selectPickupSchema,
21
+ // Tag schemas
22
+ selectTagsSchema,
23
+ // User schemas
24
+ selectUserSchema, SOCIAL_MEDIA_PLATFORMS, } from "../db/schema/index.js";
25
+ // =============================================================================
26
+ // ROUTE SCHEMAS - EVENTS
27
+ // =============================================================================
28
+ export { createEventSchema, eventResponseSchema, eventsListResponseSchema, listEventsQuerySchema, patchEventSchema, } from "../routes/events/schemas/index.js";
package/package.json CHANGED
@@ -1,33 +1,78 @@
1
1
  {
2
2
  "name": "@lcas58/esmi-api-types",
3
- "version": "1.0.4",
4
- "description": "Shared API types for ESMI frontend and backend",
5
- "main": "dist/app.d.ts",
6
- "types": "dist/app.d.ts",
3
+ "type": "module",
4
+ "version": "1.0.6",
5
+ "license": "MIT",
7
6
  "exports": {
8
7
  ".": {
9
- "types": "./dist/app.d.ts"
8
+ "types": "./dist/src/shared/index.d.ts",
9
+ "default": "./dist/src/shared/index.js"
10
+ },
11
+ "./client-types": {
12
+ "types": "./dist/src/shared/client-types.d.ts",
13
+ "default": "./dist/src/shared/client-types.js"
10
14
  }
11
15
  },
16
+ "main": "./dist/src/shared/index.js",
17
+ "types": "./dist/src/shared/index.d.ts",
12
18
  "files": [
13
- "dist/"
19
+ "dist/src/app.d.ts",
20
+ "dist/src/app.js",
21
+ "dist/src/db/schema",
22
+ "dist/src/lib/types.d.ts",
23
+ "dist/src/routes/*/schemas",
24
+ "dist/src/shared"
14
25
  ],
15
26
  "scripts": {
16
- "build": "mkdir -p dist && cp src/app.d.ts dist/app.d.ts",
27
+ "dev": "wrangler dev",
28
+ "deploy": "wrangler deploy --minify",
29
+ "start": "node ./dist/src/index.js",
30
+ "typecheck": "tsc --noEmit",
31
+ "lint": "eslint .",
32
+ "lint:fix": "npm run lint --fix",
33
+ "test": "cross-env NODE_ENV=test vitest",
34
+ "build": "tsc && tsc-alias",
17
35
  "prepublishOnly": "bun run build",
18
- "release:patch": "npm version patch && npm publish",
19
- "release:minor": "npm version minor && npm publish",
20
- "release:major": "npm version major && npm publish"
36
+ "db:studio": "bunx drizzle-kit studio",
37
+ "db:generate": "bunx drizzle-kit generate",
38
+ "db:migrate": "bunx drizzle-kit migrate",
39
+ "db:seed": "tsx src/db/seed/index.ts"
40
+ },
41
+ "peerDependencies": {
42
+ "zod": "^3.23.8"
43
+ },
44
+ "dependencies": {
45
+ "@auth/core": "^0.37.0",
46
+ "@auth/drizzle-adapter": "^1.7.0",
47
+ "@hono/zod-openapi": "^0.16.4",
48
+ "@neondatabase/serverless": "^0.10.1",
49
+ "@scalar/hono-api-reference": "^0.5.150",
50
+ "better-auth": "^1.1.9",
51
+ "dotenv": "^16.4.5",
52
+ "dotenv-expand": "^11.0.6",
53
+ "drizzle-orm": "^0.33.0",
54
+ "drizzle-zod": "^0.5.1",
55
+ "hono": "4.6.16",
56
+ "hono-pino": "^0.3.0",
57
+ "next-auth": "^4.24.8",
58
+ "pino": "^9.4.0",
59
+ "pino-pretty": "^11.2.2",
60
+ "stoker": "^1.0.9"
21
61
  },
22
- "keywords": [
23
- "typescript",
24
- "api",
25
- "types",
26
- "esmi"
27
- ],
28
- "author": "lcas58",
29
- "license": "MIT",
30
62
  "devDependencies": {
31
- "typescript": "^5.0.0"
63
+ "@antfu/eslint-config": "^3.7.3",
64
+ "@cloudflare/workers-types": "^4.20241018.0",
65
+ "@hono/node-server": "^*",
66
+ "@types/node": "^22.7.4",
67
+ "cross-env": "^7.0.3",
68
+ "drizzle-kit": "^0.24.2",
69
+ "eslint": "^9.12.0",
70
+ "eslint-plugin-format": "^0.1.2",
71
+ "tsc-alias": "^1.8.10",
72
+ "tsx": "^4.19.1",
73
+ "typescript": "^5.6.2",
74
+ "vitest": "^2.1.2",
75
+ "wrangler": "^4.34.0",
76
+ "zod": "^3.23.8"
32
77
  }
33
78
  }