Matomo + Google Ads + Google Analitycs

What is the right way to configure Google Ads to track campaign with Matomo, leaving the integration between Google Ads and Google Analytics working?
If I add a Matomo template to the advanced url parameters section of Google Ads, am I losing sync between Google Ads and Google Analytics? Is the glicd parameter lost in this way?
I refer to the instructions read here