You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Rewrite root README as an index-style overview with architecture diagram,
package tables, and key patterns explanation. Create detailed package-level
READMEs for all 7 packages (nestjs-prisma, nestjs-auth, nestjs-notifications,
nestjs-storage, nestjs-audit-log, nestjs-pagination, nestjs-response) with
consistent structure: overview, installation, configuration, API reference,
and architecture diagrams. All code examples verified against source.
Composable NestJS plugin ecosystem by [BlackBox Vision](https://github.com/BlackBoxVision). Each module is a self-contained feature with its own Prisma schema, feature flags, and provider abstractions — like NestJS plugins that bring their own DB tables, config, and toggleable capabilities.
3
+
Composable NestJS plugin ecosystem by [BlackBox Vision](https://github.com/BlackBoxVision).
4
4
5
-
Build a production-ready NestJS API by composing modules: `AuthModule`, `NotificationModule`, `StorageModule` — each bringing its schema, migrations, and feature set.
5
+
Each module is a self-contained feature -- own Prisma schema, feature flags, provider abstraction -- that you compose into a production-ready NestJS API.
6
+
7
+
## Architecture
8
+
9
+
```
10
+
Your NestJS App
11
+
|
12
+
+-- PrismaModule (@bbv/nestjs-prisma) <-- foundation, all plugins depend on this
|[`@bbv/nestjs-storage`](./packages/nestjs-storage)| File upload with provider abstraction (S3, Firebase, DO Spaces, Local) and upload tracking |[README](./packages/nestjs-storage/README.md)|
Every plugin module accepts a `features` config to toggle capabilities. Disabled features don't register routes, don't consume resources, and throw if called directly.
51
+
52
+
```typescript
53
+
AuthModule.forRootAsync({
54
+
useFactory: () => ({
55
+
jwt: { secret: 'my-secret' },
56
+
features: {
57
+
emailPassword: true, // POST /auth/register, POST /auth/login
58
+
google: false, // Google OAuth routes not registered
59
+
organizations: true, // Full /organizations CRUD
60
+
sessionManagement: false, // Session endpoints not registered
61
+
},
62
+
}),
63
+
})
64
+
```
10
65
11
-
| Package | Description | Version |
12
-
|---------|-------------|---------|
13
-
|[`@bbv/nestjs-auth`](./packages/nestjs-auth)| Authentication, social login, organizations, RBAC |[](https://www.npmjs.com/package/@bbv/nestjs-auth)|
|[`@bbv/nestjs-storage`](./packages/nestjs-storage)| File storage with provider abstraction (S3, Firebase, DO Spaces, Local) |[](https://www.npmjs.com/package/@bbv/nestjs-storage)|
16
-
|[`@bbv/nestjs-audit-log`](./packages/nestjs-audit-log)| Automatic audit logging with Prisma middleware |[](https://www.npmjs.com/package/@bbv/nestjs-audit-log)|
66
+
### Provider Abstraction
17
67
18
-
### Tier 2 — Utility Packages
68
+
Modules with swappable backends follow the same config pattern with TypeScript discriminated unions for type safety:
19
69
20
-
| Package | Description | Version |
21
-
|---------|-------------|---------|
22
-
|[`@bbv/nestjs-prisma`](./packages/nestjs-prisma)| Prisma service shell, lifecycle management, test utilities |[](https://www.npmjs.com/package/@bbv/nestjs-prisma)|
23
-
|[`@bbv/nestjs-pagination`](./packages/nestjs-pagination)| Pagination DTOs, helpers, and Swagger decorators |[](https://www.npmjs.com/package/@bbv/nestjs-pagination)|
24
-
|[`@bbv/nestjs-response`](./packages/nestjs-response)| API response wrapper, transform interceptor, exception filter |[](https://www.npmjs.com/package/@bbv/nestjs-response)|
70
+
```typescript
71
+
StorageModule.forRoot({
72
+
provider: 's3', // or 'firebase', 'do_spaces', 'local'
73
+
providerOptions: { /* typed */ }, // type narrows based on provider
74
+
})
75
+
```
76
+
77
+
### Multi-File Prisma Schema
78
+
79
+
Each Tier 1 plugin ships a `.prisma` file. Copy them into your project's schema directory:
0 commit comments