Tealiums documentation suggests to use the brackets notation like b['var_name'] fo example here:
Personally I currently stick to the brackets notation as from the documentation but i would prefere to use the dot notation for better readability in the future.
Solved! Go to Solution.
in TiQ, I'll use dot notation when I can (so I'd write your example
b.var_name). But many automatically generated names in TiQ include a dot, which forces you to use bracket notation:
That's more a technical consideration than a "best practice" I guess.
But I do agree that dot notation is easier to read, and doesn't risk dumb errors like omitting your quotes and accidentally referencing a variable instead of using a string literal.
Hope that's useful?