@lido-nestjs/execution 1.8.1 → 1.8.2

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 (2) hide show
  1. package/README.md +13 -1
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -55,7 +55,7 @@ import { ConfigModule, ConfigService } from './my.service';
55
55
 
56
56
  @Module({
57
57
  imports: [
58
- ConfigModule.forRoot(),
58
+ ConfigModule.forRoot(), // exports ConfigService
59
59
  FetchModule.forRoot(),
60
60
  FallbackProviderModule.forRootAsync({
61
61
  async useFactory(configService: ConfigService) {
@@ -69,4 +69,16 @@ import { ConfigModule, ConfigService } from './my.service';
69
69
  ],
70
70
  })
71
71
  export class MyModule {}
72
+
73
+ // Usage
74
+ import { SimpleFallbackJsonRpcBatchProvider } from '@lido-nestjs/execution';
75
+
76
+ @Injectable
77
+ export class MyService {
78
+ constructor(private provider: SimpleFallbackJsonRpcBatchProvider) {}
79
+
80
+ async doSomeWork() {
81
+ return await this.provider.getBlock(1000);
82
+ }
83
+ }
72
84
  ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lido-nestjs/execution",
3
- "version": "1.8.1",
3
+ "version": "1.8.2",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "license": "MIT",