Skip to content

Instantly share code, notes, and snippets.

@mvcds
Last active June 5, 2020 13:23
Show Gist options
  • Save mvcds/2b9701f4e18b0792188fd1e23bb1a8ab to your computer and use it in GitHub Desktop.
Save mvcds/2b9701f4e18b0792188fd1e23bb1a8ab to your computer and use it in GitHub Desktop.
c#-api
/*old interface
function makeFoo(a: number, b: FooDTO): Foo[] {}
*/
//new interface BAD
function oldMakeFooDontUseIt(a: number, b: FooDTO): Foo[] {}
function newFooMaking(a: FooDTO, b: boolean, c: number): Foo[] {}
//new interface GOOD
function makeFoo(a: number, b: FooDTO, c: boolean = false): Foo[] {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment