Skip to content

Commit

Permalink
refactor: use managed types
Browse files Browse the repository at this point in the history
  • Loading branch information
9renpoto committed Oct 22, 2023
1 parent 696ef44 commit 381ab81
Show file tree
Hide file tree
Showing 8 changed files with 1,896 additions and 1,648 deletions.
30 changes: 30 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/alpine
{
"name": "Alpine",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"image": "mcr.microsoft.com/devcontainers/base:alpine-3.18",
"features": {
"ghcr.io/cirolosapio/devcontainers-features/alpine-node:0": {}
},
"customizations": {},

"containerEnv": {
"SLACK_WEBHOOK_URL": "https://example.com"
}

// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],

// Use 'postCreateCommand' to run commands after the container is created.
// "postCreateCommand": "uname -a",

// Configure tool-specific properties.
// "customizations": {},

// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "root"
}
6 changes: 3 additions & 3 deletions example/src/config/zendesk.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { registerAs } from "@nestjs/config";
import type { ClientOptions } from "node-zendesk";
import type { ZendeskClientOptions } from "node-zendesk";

export default registerAs(
"zendesk",
(): ClientOptions => ({
(): ZendeskClientOptions => ({
username: process.env.ZENDESK_USER_NAME!,
token: process.env.ZENDESK_TOKEN!,
remoteUri: process.env.ZENDESK_REMOTE_URI!,
endpointUri: process.env.ZENDESK_REMOTE_URI!,
}),
);
4 changes: 2 additions & 2 deletions example/src/zendesk/zendesk.service.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { Injectable } from "@nestjs/common";
import { InjectZendesk } from "nestjs-zendesk";
import { Client } from "node-zendesk";
import { ZendeskClient } from "node-zendesk";

@Injectable()
export class ZendeskService {
constructor(@InjectZendesk() private readonly zendesk: Client) {}
constructor(@InjectZendesk() private readonly zendesk: ZendeskClient) {}

async ticket() {
return this.zendesk.tickets.list();
Expand Down
Loading

0 comments on commit 381ab81

Please sign in to comment.