Skip to content

Commit 0d9ba41

Browse files
committed
Fix linting errors
Signed-off-by: Shubham Sharma <[email protected]>
1 parent e930b4f commit 0d9ba41

File tree

8 files changed

+18
-6
lines changed

8 files changed

+18
-6
lines changed

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/actors/client/ActorClient/ActorClient.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ export default class ActorClient {
3535
this.communicationProtocol = communicationProtocol;
3636
this.options = options;
3737

38-
let logger = new Logger(this.options.loggerOptions);
38+
const logger = new Logger(this.options.loggerOptions);
3939

4040
// Builder
4141
switch (communicationProtocol) {

src/index.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@ import AbstractActor from "./actors/runtime/AbstractActor";
1919
import { Temporal } from "@js-temporal/polyfill";
2020
import ActorProxyBuilder from "./actors/client/ActorProxyBuilder";
2121
import ActorId from "./actors/ActorId";
22+
import { DaprClientOptions } from "./types/DaprClientOptions";
23+
import { LoggerOptions } from "./types/logger/LoggerOptions";
24+
import { LoggerService } from "./types/logger/LoggerService";
25+
import { ConsoleLoggerService } from "./logger/ConsoleLoggerService";
2226

2327
export {
2428
DaprClient,
@@ -29,4 +33,8 @@ export {
2933
ActorProxyBuilder,
3034
CommunicationProtocolEnum,
3135
Temporal,
36+
DaprClientOptions,
37+
LoggerOptions,
38+
LoggerService,
39+
ConsoleLoggerService,
3240
}

src/interfaces/Client/IClient.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ limitations under the License.
1313

1414
import CommunicationProtocolEnum from "../../enum/CommunicationProtocol.enum";
1515
import { DaprClientOptions } from "../../types/DaprClientOptions";
16-
import { LoggerOptions } from "../../types/logger/LoggerOptions";
1716

1817
export default interface IClient {
1918
getClient(): any;

src/logger/ConsoleLoggerService.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,12 @@ See the License for the specific language governing permissions and
1111
limitations under the License.
1212
*/
1313

14+
import { LoggerService } from "../types/logger/LoggerService";
15+
1416
/**
1517
* ConsoleLoggerService uses the in-built console module to log messages.
1618
*/
17-
class ConsoleLoggerService implements LoggerService {
19+
export class ConsoleLoggerService implements LoggerService {
1820
error(message: any, ...optionalParams: any[]): void {
1921
console.error(`${this.getTime()} ERROR ${message}`, ...optionalParams);
2022
}

src/logger/Logger.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ limitations under the License.
1212
*/
1313

1414
import { LoggerOptions } from "../types/logger/LoggerOptions";
15+
import { LoggerService } from "../types/logger/LoggerService";
1516
import { LogLevel } from "../types/logger/LogLevel";
17+
import { ConsoleLoggerService } from "./ConsoleLoggerService";
1618

1719
export class Logger {
1820
private readonly logLevel: LogLevel;

src/types/logger/LoggerOptions.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ See the License for the specific language governing permissions and
1111
limitations under the License.
1212
*/
1313

14+
import { LoggerService } from "./LoggerService"
1415
import { LogLevel } from "./LogLevel"
1516

1617
/**

src/types/logger/LoggerService.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ limitations under the License.
1414
/**
1515
* LoggerService provides an interface to log SDK messages.
1616
*/
17-
interface LoggerService {
17+
export interface LoggerService {
1818

1919
/**
2020
* Write an 'error' level log.

0 commit comments

Comments
 (0)