This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* | |
* Complete the following 2 types of 'CreateRequest' and 'GetParams'. | |
* 完善下述两个类型 'CreateRequest' 和 'GetParams'。 | |
* | |
**/ | |
// improve type of CreateRequest | |
type CreateRequest = unknown |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* 给定数组,转换为对象类型,键/值必须在给定数组中。 | |
**/ | |
// Example: | |
const tuple = ['tesla', 'model 3', 'model X', 'model Y'] as const | |
const result: TupleToObject<typeof tuple> // expected { tesla: 'tesla', 'model 3': 'model 3', 'model X': 'model X', 'model Y': 'model Y'} |
OlderNewer