Brian Rinaldi is a Developer Experience Engineer at LaunchDarkly with over 20 years experience as a developer for the web. Brian is active in the community running CFE.dev and Orlando Devs.
Thanks. Yes, I didn't bring them up because I thought it might sidetrack the discussion of const a bit but if immutability really matters for what you are doing, then definitely.
You should check out Object.freeze if you want
constto be immutable or Object.seal if you wantconstto just be a little bit mutable.Thanks. Yes, I didn't bring them up because I thought it might sidetrack the discussion of
consta bit but if immutability really matters for what you are doing, then definitely.I had always assumed they were immutable, was shocked to find they weren't.
The immutability was the key reason I started to use them.