📜  javascript es6 中的枚举 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:12.955000             🧑  作者: Mango

代码示例4
const daysEnum = Object.freeze({
  monday: Symbol(0),
  tuesday: Symbol(1),
  wednesday: Symbol(2),
  thursday: Symbol(3),
  friday: Symbol(4),
  saturday: Symbol(5),
  sunday: Symbol(6)
});