diff --git a/apps/docs/src/pages/en/nestjs/graphql/platform-graphql-fastify.md b/apps/docs/src/pages/en/nestjs/graphql/platform-graphql-fastify.md index b3a7fb7f6..3e2692d52 100644 --- a/apps/docs/src/pages/en/nestjs/graphql/platform-graphql-fastify.md +++ b/apps/docs/src/pages/en/nestjs/graphql/platform-graphql-fastify.md @@ -14,7 +14,7 @@ The `GraphQLFastifyParser` parser for the `OgmaInterceptor`. This plugin class p ## Installation -Nothing special, standard `npm i @ogma/platform-graphql-fastify` or `yarn add @ogma/platform-graphql-fastify` +Nothing special, standard `npm i @ogma/platform-graphql-fastify` or `yarn add @ogma/platform-graphql-fastify` or `pnpm add @ogma/platform-graphql-fastify` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/graphql/platform-graphql.md b/apps/docs/src/pages/en/nestjs/graphql/platform-graphql.md index f1c7b41e1..1b08eea55 100644 --- a/apps/docs/src/pages/en/nestjs/graphql/platform-graphql.md +++ b/apps/docs/src/pages/en/nestjs/graphql/platform-graphql.md @@ -8,7 +8,7 @@ The `GraphQLParser` parser for the `OgmaInterceptor`. This plugin class parses G ## Installation -Nothing special, standard `npm i @ogma/platform-graphql` or `yarn add @ogma/platform-graphql` +Nothing special, standard `npm i @ogma/platform-graphql` or `yarn add @ogma/platform-graphql` or `pnpm add @ogma/platform-graphql` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/http/platform-express.md b/apps/docs/src/pages/en/nestjs/http/platform-express.md index 881f93d5a..ae2e017cd 100644 --- a/apps/docs/src/pages/en/nestjs/http/platform-express.md +++ b/apps/docs/src/pages/en/nestjs/http/platform-express.md @@ -8,7 +8,7 @@ The `ExpressInterceptorParser` parser for the `OgmaInterceptor`. This plugin cla ## Installation -Nothing special, standard `npm i @ogma/platform-express` or `yarn add @ogma/platform-express` +Nothing special, standard `npm i @ogma/platform-express` or `yarn add @ogma/platform-express` or `pnpm add @ogma/platform-express` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/http/platform-fastify.md b/apps/docs/src/pages/en/nestjs/http/platform-fastify.md index 9991a6013..621e349ae 100644 --- a/apps/docs/src/pages/en/nestjs/http/platform-fastify.md +++ b/apps/docs/src/pages/en/nestjs/http/platform-fastify.md @@ -8,7 +8,7 @@ The `FastifyInterceptorParser` parser for the `OgmaInterceptor`. This plugin cla ## Installation -Nothing special, standard `npm i @ogma/platform-fastify` or `yarn add @ogma/platform-fastify` +Nothing special, standard `npm i @ogma/platform-fastify` or `yarn add @ogma/platform-fastify` or `pnpm add @ogma/platform-fastify` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/rpc/grpc.md b/apps/docs/src/pages/en/nestjs/rpc/grpc.md index b5bcdd3f4..81a5b82de 100644 --- a/apps/docs/src/pages/en/nestjs/rpc/grpc.md +++ b/apps/docs/src/pages/en/nestjs/rpc/grpc.md @@ -8,7 +8,7 @@ The `GrpcParser` parser for the `OgmaInterceptor`. This plugin class parses gRPC ## Installation -Nothing special, standard `npm i @ogma/platform-grpc` or `yarn add @ogma/platform-grpc` +Nothing special, standard `npm i @ogma/platform-grpc` or `yarn add @ogma/platform-grpc` or `pnpm add @ogma/platform-grpc` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/rpc/kafka.md b/apps/docs/src/pages/en/nestjs/rpc/kafka.md index c14105bbe..8883a9e1c 100644 --- a/apps/docs/src/pages/en/nestjs/rpc/kafka.md +++ b/apps/docs/src/pages/en/nestjs/rpc/kafka.md @@ -8,7 +8,7 @@ The `KafkaParser` parser for the `OgmaInterceptor`. This plugin class parses Kaf ## Installation -Nothing special, standard `npm i @ogma/platform-kafka` or `yarn add @ogma/platform-kafka` +Nothing special, standard `npm i @ogma/platform-kafka` or `yarn add @ogma/platform-kafka` or `pnpm add @ogma/platform-kafka` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/rpc/mqtt.md b/apps/docs/src/pages/en/nestjs/rpc/mqtt.md index 9a3a8decb..1fb377c4e 100644 --- a/apps/docs/src/pages/en/nestjs/rpc/mqtt.md +++ b/apps/docs/src/pages/en/nestjs/rpc/mqtt.md @@ -8,7 +8,7 @@ The `MqttParser` parser for the `OgmaInterceptor`. This plugin class parses MQTT ## Installation -Nothing special, standard `npm i @ogma/platform-mqtt` or `yarn add @ogma/platform-mqtt` +Nothing special, standard `npm i @ogma/platform-mqtt` or `yarn add @ogma/platform-mqtt` or `pnpm add @ogma/platform-mqtt` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/rpc/nats.md b/apps/docs/src/pages/en/nestjs/rpc/nats.md index 45e3fc2e2..0fd0e0b37 100644 --- a/apps/docs/src/pages/en/nestjs/rpc/nats.md +++ b/apps/docs/src/pages/en/nestjs/rpc/nats.md @@ -8,7 +8,7 @@ The `NatsParser` parser for the `OgmaInterceptor`. This plugin class parses NATS ## Installation -Nothing special, standard `npm i @ogma/platform-nats` or `yarn add @ogma/platform-nats` +Nothing special, standard `npm i @ogma/platform-nats` or `yarn add @ogma/platform-nats` or `pnpm add @ogma/platform-nats` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/rpc/rabbitmq.md b/apps/docs/src/pages/en/nestjs/rpc/rabbitmq.md index 05f99e06f..11ea6122c 100644 --- a/apps/docs/src/pages/en/nestjs/rpc/rabbitmq.md +++ b/apps/docs/src/pages/en/nestjs/rpc/rabbitmq.md @@ -8,7 +8,7 @@ The `RabbitMqParser` parser for the `OgmaInterceptor`. This plugin class parses ## Installation -Nothing special, standard `npm i @ogma/platform-rabbitmq` or `yarn add @ogma/platform-rabbitmq` +Nothing special, standard `npm i @ogma/platform-rabbitmq` or `yarn add @ogma/platform-rabbitmq` or `pnpm add @ogma/platform-rabbitmq` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/rpc/redis.md b/apps/docs/src/pages/en/nestjs/rpc/redis.md index 630aef7f6..296a97a49 100644 --- a/apps/docs/src/pages/en/nestjs/rpc/redis.md +++ b/apps/docs/src/pages/en/nestjs/rpc/redis.md @@ -8,7 +8,7 @@ The `RedisParser` parser for the `OgmaInterceptor`. This plugin class parses Red ## Installation -Nothing special, standard `npm i @ogma/platform-redis` or `yarn add @ogma/platform-redis` +Nothing special, standard `npm i @ogma/platform-redis` or `yarn add @ogma/platform-redis` or `pnpm add @ogma/platform-redis` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/rpc/tcp.md b/apps/docs/src/pages/en/nestjs/rpc/tcp.md index 7cdb33180..32a72007e 100644 --- a/apps/docs/src/pages/en/nestjs/rpc/tcp.md +++ b/apps/docs/src/pages/en/nestjs/rpc/tcp.md @@ -8,7 +8,7 @@ The `TcpParser` parser for the `OgmaInterceptor`. This plugin class parses TCP r ## Installation -Nothing special, standard `npm i @ogma/platform-tcp` or `yarn add @ogma/platform-tcp` +Nothing special, standard `npm i @ogma/platform-tcp` or `yarn add @ogma/platform-tcp` or `pnpm add @ogma/platform-tcp` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/ws/socket.io.md b/apps/docs/src/pages/en/nestjs/ws/socket.io.md index 737f6035f..3e19bb6ef 100644 --- a/apps/docs/src/pages/en/nestjs/ws/socket.io.md +++ b/apps/docs/src/pages/en/nestjs/ws/socket.io.md @@ -8,7 +8,7 @@ The `SocketIOParser` parser for the `OgmaInterceptor`. This plugin class parses ## Installation -Nothing special, standard `npm i @ogma/platform-socket.io` or `yarn add @ogma/platform-socket.io` +Nothing special, standard `npm i @ogma/platform-socket.io` or `yarn add @ogma/platform-socket.io` or `pnpm add @ogma/platform-socket.io` ## Usage diff --git a/apps/docs/src/pages/en/nestjs/ws/ws.md b/apps/docs/src/pages/en/nestjs/ws/ws.md index c621e50ea..b5858547f 100644 --- a/apps/docs/src/pages/en/nestjs/ws/ws.md +++ b/apps/docs/src/pages/en/nestjs/ws/ws.md @@ -8,7 +8,7 @@ The `WsParser` parser for the `OgmaInterceptor`. This plugin class parses TCP re ## Installation -Nothing special, standard `npm i @ogma/platform-ws` or `yarn add @ogma/platform-ws` +Nothing special, standard `npm i @ogma/platform-ws` or `yarn add @ogma/platform-ws` or `pnpm add @ogma/platform-ws` ## Usage diff --git a/packages/nestjs-module/README.md b/packages/nestjs-module/README.md index 4a5122921..8cab5f53e 100644 --- a/packages/nestjs-module/README.md +++ b/packages/nestjs-module/README.md @@ -4,7 +4,7 @@ A [NestJS module](https://docs.nestjs.com) for the [Ogma](https://github.com/jmc ## Installation -Installation is pretty simple, just `npm i @ogma/nestjs-module` or `yarn add @ogma/nestjs-module` +Installation is pretty simple, just `npm i @ogma/nestjs-module` or `yarn add @ogma/nestjs-module` or `pnpm add @ogma/nestjs-module` ## Usage @@ -21,22 +21,13 @@ In your root module, import `OgmaModule.forRoot` or `OgmaModule.forRootAsync` to ```ts import { APP_INTERCEPTOR } from '@nestjs/core'; import { OgmaInterceptor, OgmaModule } from '@ogma/nestjs-module'; -import { ExpressParser } from '@ogma/platform-express'; @Module({ imports: [ OgmaModule.forRoot({ - service: { - color: true, - json: false, - application: 'NestJS' - }, - interceptor: { - http: ExpressParser, - ws: false, - gql: false, - rpc: false - } + color: true, + json: false, + application: 'NestJS' }) ], providers: [ @@ -76,12 +67,6 @@ import { appendFile } from 'fs'; }, application: config.getAppName() }, - interceptor: { - http: ExpressParser, - ws: false, - gql: false, - rpc: false - } }), inject: [ConfigService] }) @@ -199,7 +184,6 @@ As the pre-built parsers are built around Object Oriented Typescript, if you wan Okay, so now we're ready to add the `OgmaModule` to our Application. Let's assume we have a `CatsService`, `CatsController` and `CatsModule` and a `ConfigService` and `ConfigModule` in our Application. Let's also assume we want to use a class to asynchronously configure out `OgmaModule`. For now, assume the methods exist on the `ConfigService`. Let's also assume we want to log things in color to our `process.stdout`. ```ts -import { FastifyParser } from '@ogma/platform-fastify'; import { OgmaModuleOptions } from '@ogma/nestjs-module'; @Injectable() @@ -208,22 +192,18 @@ export class OgmaModuleConfig { createModuleConfig(): OgmaModuleOptions { return { - service: { // returns one of Ogma's log levels, or 'ALL'. logLevel: this.configService.getLogLevel(), color: true, // could be something like 'MyAwesomeNestApp' application: this.configService.getAppName() - }, - interceptor: { - http: FastifyParser } }; } } ``` -Next, in our `AppModule` we can import the `OgmaModule` like so +Next, in our `AppModule` we can import the `OgmaModule` and `FastifyParser` like so ```ts @Module({ @@ -235,7 +215,8 @@ Next, in our `AppModule` we can import the `OgmaModule` like so useClass: OgmaModuleConfig, imports: [ConfigModule] }) - ] + ], + providers: [FastifyParser] }) export class AppModule {} ``` diff --git a/packages/platform-express/README.md b/packages/platform-express/README.md index dfb2b5eb3..b98340ca5 100644 --- a/packages/platform-express/README.md +++ b/packages/platform-express/README.md @@ -4,19 +4,16 @@ The `ExpressInterceptorParser` parser for the `OgmaInterceptor`. This plugin cla ## Installation -Nothing special, standard `npm i @ogma/platform-express` or `yarn add @ogma/platform-express` +Nothing special, standard `npm i @ogma/platform-express` or `yarn add @ogma/platform-express` or `pnpm add @ogma/platform-express` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - http: ExpressParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [ExpressParser] +}) export class AppModule {} ``` diff --git a/packages/platform-fastify/README.md b/packages/platform-fastify/README.md index cad851ed5..9151828e2 100644 --- a/packages/platform-fastify/README.md +++ b/packages/platform-fastify/README.md @@ -4,19 +4,16 @@ The `FastifyInterceptorParser` parser for the `OgmaInterceptor`. This plugin cla ## Installation -Nothing special, standard `npm i @ogma/platform-fastify` or `yarn add @ogma/platform-fastify` +Nothing special, standard `npm i @ogma/platform-fastify` or `yarn add @ogma/platform-fastify` or `pnpm add @ogma/platform-fastify` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - http: FastifyParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [FastifyParser] +}) export class AppModule {} ``` diff --git a/packages/platform-graphql-fastify/README.md b/packages/platform-graphql-fastify/README.md index b663983f7..93b906c21 100644 --- a/packages/platform-graphql-fastify/README.md +++ b/packages/platform-graphql-fastify/README.md @@ -1,23 +1,22 @@ # `@ogma/platform-graphql-fastify` +> Note: If you are using `@nestjs/apollo` make sure you are using fastify v3 and `@nestjs/common` version 8. If you are using`@nestjs/mercurius`you may use fastify v4 and`@nestjs/common` version 9. + The `GraphQLFastifyParser` parser for the `OgmaInterceptor`. This plugin class parses GraphQL request and response object to be able to successfully log the data about the request. For more information, check out [the @ogma/nestjs-module](../nestjs-module/README.md) documentation. ## Installation -Nothing special, standard `npm i @ogma/platform-graphql-fastify` or `yarn add @ogma/platform-graphql-fastify` +Nothing special, standard `npm i @ogma/platform-graphql-fastify` or `yarn add @ogma/platform-graphql-fastify` or `pnpm add @ogma/platform-graphql-fastify` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - gql: GraphQLFastifyParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [GraphQLFastifyParser] +}) export class AppModule {} ``` diff --git a/packages/platform-graphql/README.md b/packages/platform-graphql/README.md index 553c3cf1b..59e19ccde 100644 --- a/packages/platform-graphql/README.md +++ b/packages/platform-graphql/README.md @@ -4,20 +4,17 @@ The `GraphQLParser` parser for the `OgmaInterceptor`. This plugin class parses G ## Installation -Nothing special, standard `npm i @ogma/platform-graphql` or `yarn add @ogma/platform-graphql` +Nothing special, standard `npm i @ogma/platform-graphql` or `yarn add @ogma/platform-graphql` or `pnpm add @ogma/platform-graphql` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - gql: GraphQLParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [GraphQLParser] +}) export class AppModule {} ``` diff --git a/packages/platform-grpc/README.md b/packages/platform-grpc/README.md index c184d8b54..def785e86 100644 --- a/packages/platform-grpc/README.md +++ b/packages/platform-grpc/README.md @@ -4,19 +4,17 @@ The `GrpcParser` parser for the `OgmaInterceptor`. This plugin class parses Kafk ## Installation -Nothing special, standard `npm i @ogma/platform-grpc` or `yarn add @ogma/platform-grpc` +Nothing special, standard `npm i @ogma/platform-grpc` or `yarn add @ogma/platform-grpc` or `pnpm add @ogma/platform-grpc` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - rpc: GrpcParser - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [GrpcParser] +}) export class AppModule {} ``` diff --git a/packages/platform-kafka/README.md b/packages/platform-kafka/README.md index 03446a846..9b0e70bc2 100644 --- a/packages/platform-kafka/README.md +++ b/packages/platform-kafka/README.md @@ -4,19 +4,17 @@ The `KafkaParser` parser for the `OgmaInterceptor`. This plugin class parses Kaf ## Installation -Nothing special, standard `npm i @ogma/platform-kafka` or `yarn add @ogma/platform-kafka` +Nothing special, standard `npm i @ogma/platform-kafka` or `yarn add @ogma/platform-kafka` or `pnpm add @ogma/platform-kafka` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - rpc: KafkaParser - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [KafkaParser] +}) export class AppModule {} ``` diff --git a/packages/platform-mqtt/README.md b/packages/platform-mqtt/README.md index e06f2456e..245b0d6c4 100644 --- a/packages/platform-mqtt/README.md +++ b/packages/platform-mqtt/README.md @@ -4,20 +4,17 @@ The `MqttParser` parser for the `OgmaInterceptor`. This plugin class parses MQTT ## Installation -Nothing special, standard `npm i @ogma/platform-mqtt` or `yarn add @ogma/platform-mqtt` +Nothing special, standard `npm i @ogma/platform-mqtt` or `yarn add @ogma/platform-mqtt` or `pnpm add @ogma/platform-mqtt` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - rpc: MqttParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [MqttParser] +}) export class AppModule {} ``` diff --git a/packages/platform-nats/README.md b/packages/platform-nats/README.md index 83e264f48..ac15f6d06 100644 --- a/packages/platform-nats/README.md +++ b/packages/platform-nats/README.md @@ -4,20 +4,17 @@ The `NatsParser` parser for the `OgmaInterceptor`. This plugin class parses NATS ## Installation -Nothing special, standard `npm i @ogma/platform-nats` or `yarn add @ogma/platform-nats` +Nothing special, standard `npm i @ogma/platform-nats` or `yarn add @ogma/platform-nats` or `pnpm add @ogma/platform-nats` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - rpc: NatsParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [NatsParser] +}) export class AppModule {} ``` diff --git a/packages/platform-rabbitmq/README.md b/packages/platform-rabbitmq/README.md index 774977152..d8e997201 100644 --- a/packages/platform-rabbitmq/README.md +++ b/packages/platform-rabbitmq/README.md @@ -4,20 +4,17 @@ The `RabbitMqParser` parser for the `OgmaInterceptor`. This plugin class parses ## Installation -Nothing special, standard `npm i @ogma/platform-rabbitmq` or `yarn add @ogma/platform-rabbitmq` +Nothing special, standard `npm i @ogma/platform-rabbitmq` or `yarn add @ogma/platform-rabbitmq` or `pnpm add @ogma/platform-rabbitmq` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - rpc: RabbitMqParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [RabbitMqParser] +}) export class AppModule {} ``` diff --git a/packages/platform-redis/README.md b/packages/platform-redis/README.md index c9ce66943..4ebcbf233 100644 --- a/packages/platform-redis/README.md +++ b/packages/platform-redis/README.md @@ -4,20 +4,17 @@ The `RedisParser` parser for the `OgmaInterceptor`. This plugin class parses Red ## Installation -Nothing special, standard `npm i @ogma/platform-redis` or `yarn add @ogma/platform-redis` +Nothing special, standard `npm i @ogma/platform-redis` or `yarn add @ogma/platform-redis` or `pnpm add @ogma/platform-redis` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - rpc: RedisParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [RedisParser] +}) export class AppModule {} ``` diff --git a/packages/platform-socket.io/README.md b/packages/platform-socket.io/README.md index dd9d8e749..e80858d06 100644 --- a/packages/platform-socket.io/README.md +++ b/packages/platform-socket.io/README.md @@ -4,20 +4,17 @@ The `SocketIOParser` parser for the `OgmaInterceptor`. This plugin class parses ## Installation -Nothing special, standard `npm i @ogma/platform-socket.io` or `yarn add @ogma/platform-socket.io` +Nothing special, standard `npm i @ogma/platform-socket.io` or `yarn add @ogma/platform-socket.io` or `pnpm add @ogma/platform-socket.io` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - ws: SocketIOParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [SocketIOParser] +}) export class AppModule {} ``` diff --git a/packages/platform-tcp/README.md b/packages/platform-tcp/README.md index 3e2ef1e2a..809565bf8 100644 --- a/packages/platform-tcp/README.md +++ b/packages/platform-tcp/README.md @@ -4,19 +4,16 @@ The `TcpParser` parser for the `OgmaInterceptor`. This plugin class parses TCP r ## Installation -Nothing special, standard `npm i @ogma/platform-tcp` or `yarn add @ogma/platform-tcp` +Nothing special, standard `npm i @ogma/platform-tcp` or `yarn add @ogma/platform-tcp` or `pnpm add @ogma/platform-tcp` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - rpc: TcpParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [TcpParser] +}) export class AppModule {} ``` diff --git a/packages/platform-ws/README.md b/packages/platform-ws/README.md index 834323f41..739759b1d 100644 --- a/packages/platform-ws/README.md +++ b/packages/platform-ws/README.md @@ -4,20 +4,17 @@ The `WsParser` parser for the `OgmaInterceptor`. This plugin class parses TCP re ## Installation -Nothing special, standard `npm i @ogma/platform-ws` or `yarn add @ogma/platform-ws` +Nothing special, standard `npm i @ogma/platform-ws` or `yarn add @ogma/platform-ws` or `pnpm add @ogma/platform-ws` ## Usage This plugin is to be used in the `OgmaInterceptorOptions` portion of the `OgmaModule` during `forRoot` or `forRootAsync` registration. It can be used like so: ```ts -@Module( - OgmaModule.forRoot({ - interceptor: { - ws: WsParser - } - }) -) +@Module({ + imports: [OgmaModule.forRoot({})], + providers: [WsParser] +}) export class AppModule {} ```