我想将这本PHP的文字转换成文字(nodejs)。
$fruits = [
APPLE => [
color => red ,
size => small
],
BANANA =>[
color => yellow ,
size => middle
]
];
echo $fruits[ APPLE ][ color ];
type info = {
color: string,
size: string
}
const fruits[ APPLE ]: info = {color: red ,size: small }
我有了一个错误。