typescript function (config:SquareConfig): what is the meaning in the curly braces after {color:string, area: number}? Isn"t the
config attribute specified by the interface SquareConfig? What is the function of
{color:string, area: number}
interface SquareConfig {
color?: string
width?: number
}
// {color:string, area: number}
function createSquare(config: SquareConfig): {color:string, area: number}{
}