📅  最后修改于: 2022-03-11 14:59:24.897000             🧑  作者: Mango
let numValue=100; //primitive number
let numObject = new Number(1500); //Number object
numValue=numObject; //Compile Error
numObject=numValue; //ok
***** Error *****
Type 'Number' is not assignable to type 'number'.
'number' is a primitive, but 'Number' is a wrapper object. Prefer using 'number' when possible.ts(2322)