I was researching an earlier issue with rails and I stumbled across a
document which mentioned something that sounded to me like "Due to a
recent shift in the mind-set of the community, it is frowned upon to
use a string literal in any situation which does not require text
manipulation; use symbols instead." Did I interpret the info on that
page correctly?
Also, any further info you can give me about when I should be using
literals and when to use symbols would be very much appreciated.
Also, any other tips on best-practice or links to good resources about
such would be rad.
I was researching an earlier issue with rails and I stumbled across a
document which mentioned something that sounded to me like "Due to a
recent shift in the mind-set of the community, it is frowned upon to
use a string literal in any situation which does not require text
manipulation; use symbols instead." Did I interpret the info on that
page correctly?
No idea, since I don't know what page you're referring to, but it
sounds reasonable.
One reason to use symbols is that there is only *one* :foo, but there
are many "foo"'s. That is...