It works
interface test{
imp():number;
}
but you can implement the function inside.
interface test{
imp():number{
// do something if it is not overwritten
}
}
This does not work in typescript for me, but there may be some kind of reserved word, for example, by default or the like, to implement a function inside the interface that is not overwritten if the work by default works.
source
share