Having prefix "wg" is definitely a pattern, but look at different use cases to figure out best option for you. Is it only VE accessing visualEditorPreferred? Maybe it that case it would make sense to have VE export that variable for itself?