I wanted to comment on that persistent data point that on Apple platforms, you’ll have NSUserDefaults (objc) and UserDefaults.myVar (Swift). It works just like the author wishes. Other than single thread access, there’s no major problems with it. If you design your program in a way that it falls apart if the use of it is not regulated, that’s on you.