Object Tap
Quick test how tap
, then
methods of ruby lang work.
Quick test how tap
, then
methods of ruby lang work.
I did some tests on javascript object.
Here is type code in this tests.
interface Country {
name: string;
}
interface Customer {
name: string;
country?: Country
};
It is quick memo to fix TS7053 error, it took a while to fix it on other day. Here is a example code.
interface PointCondition {
pleasurePoint: number;
steamerLane: number;
};
const state: PointCondition = {
pleasurePoint: 88,
steamerLane: 92,
};
function getCondition(key: string) : number {
return state[key];
};
Object.keys(state).forEach(function(key){
return console.log( getCondition(key) );
})