New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PathValue #31968
Labels
new-challenge
Propose a new challenge, a PR will be auto generated
Comments
jw-r
added
the
new-challenge
Propose a new challenge, a PR will be auto generated
label
Jan 31, 2024
#31969 - Pull Request updated. |
Thanks, but isn't this duplicated with https://github.com/type-challenges/type-challenges/blob/main/questions/00270-hard-typed-get/README.md ? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Info
Basic info of your challenge questions,
Question
In this challenge, you are tasked with creating a type PathValue that will take an object and a string representing the path to a certain value within the object. Your job is to return the type of the value at that path. This will test your skills in generics, conditional types, and type inference.
Here's an example to get you started:
Template
This is the template for challengers to start the coding. Basically, you just need to change the name of your generic/function and leave to implementation
any
.Test Cases
Provide some test cases for your challenge, you can use some utils from
@type-challenges/utils
for asserting.The text was updated successfully, but these errors were encountered: