Move the TODO's up
This commit is contained in:
parent
a4f5af3ea5
commit
1c48e57ea1
@ -5,6 +5,9 @@
|
|||||||
* infer TypeScript interfaces from that using infer in template literal types.
|
* infer TypeScript interfaces from that using infer in template literal types.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
// TODO: get generics working
|
||||||
|
// TODO: how to pass config?
|
||||||
|
|
||||||
const create = createFactory<{
|
const create = createFactory<{
|
||||||
number: number
|
number: number
|
||||||
bigint: bigint
|
bigint: bigint
|
||||||
@ -12,12 +15,11 @@ const create = createFactory<{
|
|||||||
any: any
|
any: any
|
||||||
}>()
|
}>()
|
||||||
|
|
||||||
|
|
||||||
// These are our string based interfaces, which we can use both in typed-function and in TypeScript:
|
// These are our string based interfaces, which we can use both in typed-function and in TypeScript:
|
||||||
const Multiply = 'multiply(number,number)=>number'
|
const Multiply = 'multiply(number,number)=>number'
|
||||||
const Sqrt = 'sqrt(number)=>number'
|
const Sqrt = 'sqrt(number)=>number'
|
||||||
const Zero = 'zero(number)=>number'
|
const Zero = 'zero(number)=>number'
|
||||||
// TODO: get generics working
|
|
||||||
// TODO: how to pass config?
|
|
||||||
|
|
||||||
const createSquare = create(Sqrt, [Multiply, Zero],dep =>
|
const createSquare = create(Sqrt, [Multiply, Zero],dep =>
|
||||||
x => dep.multiply(x, x)
|
x => dep.multiply(x, x)
|
||||||
|
Loading…
Reference in New Issue
Block a user