@aravfshadow144 - There are various reasons, but I'd wager that these are the most common/relevant:
- Reduce or eliminate duplication in the analytics call - Using dynamic variables cleans up the request, making it easier to do a quick, visual check as the data is captured.
- Limit the character length of the analytics request - Older browsers (IE9, for example), had a limitation of 2048 characters. Anything beyond that length would be truncated, potentially causing issues with data collection. (This could be a real issue when capturing URLs and referrers in additional custom variables. So, rather than passing c1='https://.............' to store the current URL in a prop, simply passing c1='D=g' was the way to go.)
- Ensure consistency - Due to timing, JS errors, or any number of other issues, populating variables with an explicit value can sometimes run into issues. With dynamic variables, you can ensure the logic runs once and that all custom variables (props/eVars) are populated correctly.
Are dynamic variables required? Certainly not. Helpful? I'd argue that they are. But, then again, I still have a fondness for working directly with the AppMeasurement library.