Skip to content
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

types key of with index type #3

Closed
uittorio opened this issue Jan 19, 2019 · 1 comment
Closed

types key of with index type #3

uittorio opened this issue Jan 19, 2019 · 1 comment
Assignees

Comments

@uittorio
Copy link
Member

uittorio commented Jan 19, 2019

When trying to mock this type it will correctly returns the properties of Class but not the value of it

class Class {
 a: string
}

type KeyOf = {[key in keyof Class]: Class[key]};
const mock = createMock<KeyOf>();
mock.a // null. Should be ""
@Pmyl
Copy link
Collaborator

Pmyl commented Dec 30, 2019

This functionality was added in version 1.4.2

@Pmyl Pmyl closed this as completed Dec 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants