---
title: "#ts-challenges articles | Hashnode"
description: "Explore 2 articles tagged #ts-challenges on Hashnode. Tutorials, guides, and how-tos from the community."
url: "https://hashnode.com/tag/ts-challenges"
---

Tag

# #ts-challenges

2 posts · 0 followers

[mmyeon](https://hashnode.com/@yarnmi) · [May 26, 2025](https://hashnode.com/posts/ts-challenges-get-return-type-omit-readonly/6833ef6a1cd94bb9c9e63bc6)

### [\[ts-challenges\] Get Return Type / Omit / Readonly](https://yarnmi.hashnode.dev/ts-challenges-get-return-type-omit-readonly?utm_source=hashnode&utm_medium=feed)

Get Return Type 설계 의도 제네릭 T타입을 파라미터가 있는 함수 타입으로 정의하기 리턴 타입을 추론하기 위해 infer R 를 사용해서 타입 추론 후 리턴하기 코드 /\* \_\_\_\_\_\_\_\_\_\_\_\_\_ Your Code Here \_\_\_\_\_\_\_\_\_\_\_\_\_ \*/ type MyReturnType<T extends (...args:any\[\]) => any> = T extends (...args:any\[\])=>infer R ? R : ne...

2 min read · [yarnmi.hashnode.dev](https://yarnmi.hashnode.dev/ts-challenges-get-return-type-omit-readonly?utm_source=hashnode&utm_medium=feed)

[mmyeon](https://hashnode.com/@yarnmi) · [May 23, 2025](https://hashnode.com/posts/ts-challenges-includes-push-unshift-parameters/683005ec9812132598fe1fdb)

### [\[ts-challenges\] Includes / Push / Unshift / Parameters](https://yarnmi.hashnode.dev/ts-challenges-includes-push-unshift-parameters?utm_source=hashnode&utm_medium=feed)

Includes 설계 의도 튜플 타입 T를 첫 번째 요소인 Head와 나머지 요소들인 Tail로 분리해서 추론한다. Head가 제네릭 U 타입과 동일하지 않으면 Includes 타입을 Tail에 대해 재귀적으로 다시 실행하면서 다음 요소 검사하기 boolean 타입의 경우, true와 false이 모두 할당가능하니까 엄격하게 동등한지 비교하기 위해서 Equal 헬퍼함수 사용 코드 type Equal<X, Y> = (<T>() => ...

3 min read · [yarnmi.hashnode.dev](https://yarnmi.hashnode.dev/ts-challenges-includes-push-unshift-parameters?utm_source=hashnode&utm_medium=feed)
