Can Javascript be re-used in RRDG?
Accepted answer
RPE/RRDG 2.1 added support for Javascript reuse. If DNG/RQM/RTC you're using has RRDG 2.1 and above, you could reuse Javascript. For more details, see https://rpeactual.com/2016/06/15/new-in-rpe-2-1-reuse-javascript-functions-in-template/
Comments
It doesn't look like any DNG is using RRDG 2.1, unless 6.0.4 moved to it
CLM 6.0.4 adopted RRDG 2.1.2. Hence, it should be available. It is better to create independent function and re-use it everywhere. If you want to re-use javascript variable with value, it won't work. Use RPE variable for such cases.