%% date:: [[2022-08-16]] %% # [[TypeScript type information]] In [[TypeScript]], you can define variable type using a shorthand using `:` and `=>` ("fat arrow"), such that what comes between those two is the type. For example: ```ts var MakePoint: () => {x: number; y: number;}; ``` means that `MakePoint` is a function that takes no arguments (otherwise there would be an argument between the parentheses) and returns an object with two numbers, `x` and `y`. In contrast, in ```ts var MakePoint = function () { return 1; }; ``` the `=>` comes after the assignment operator `=`, which means that instead of defining all instances of `MakePoint` as this function, you're assigning __this particular instance__ to hold the function. [^stackoverflow] ## References [^stackoverflow]: [Stackoverflow](https://stackoverflow.com/questions/34274520/whats-the-meaning-of-in-typescript-fat-arrow)