Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/khaki-nails-hear.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@definitelytyped/utils": patch
---

Remove unused type param from misc functions
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
workflow_dispatch:

env:
NODE_VERSION: '18.x' # set this to the node version to use (supports 8.x, 10.x, 12.x)
NODE_VERSION: '20.x' # set this to the node version to use (supports 8.x, 10.x, 12.x)
RESOURCE_GROUP_NAME: dtmergebot3
FUNCTION_APP_NAME: dtmergebot3
STORAGE_ACCOUNT_NAME: dtmergebot3b1b7
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
]
},
"ignoredBuiltDependencies": [
"@parcel/watcher",
"core-js",
"core-js-pure",
"unrs-resolver",
Expand Down
3 changes: 2 additions & 1 deletion packages/typescript-packages/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@
"rootDir": "src",
"outDir": "dist"
},
"include": ["src"]
"include": ["src"],
"references": [{ "path": "../typescript-versions" }]
}
4 changes: 2 additions & 2 deletions packages/utils/src/miscellany.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import crypto from "crypto";
import { Minimatch } from "minimatch";

export function tryParseJson<T>(text: string): unknown;
export function tryParseJson(text: string): unknown;
export function tryParseJson<T>(text: string, predicate: (parsed: unknown) => parsed is T): T | undefined;
export function tryParseJson<T>(text: string, predicate?: (parsed: unknown) => parsed is T) {
try {
Expand All @@ -11,7 +11,7 @@ export function tryParseJson<T>(text: string, predicate?: (parsed: unknown) => p
}
}

export function parseJson<T>(text: string): unknown;
export function parseJson(text: string): unknown;
export function parseJson<T>(text: string, predicate?: (parsed: unknown) => parsed is T): T;
export function parseJson<T>(text: string, predicate: (parsed: unknown) => parsed is T = (_): _ is T => true) {
let parsed: unknown;
Expand Down
8 changes: 4 additions & 4 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading