How to effectively use Google tag (gtag.js) in your website?

<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-1FE2VD07E4"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());

  gtag('config', 'G-1FE2VD07E4');
</script>

Hey @loungkaye21

Is there some problem with the code?