Firebase Analytics for Webapp on a subdomain

Viewed 101

I'm quite new using Firebase Analytics for Web.

Here is my setup:

I currently set up Google Analytics only on the webapp trough Firebase Analytics

I'm wondering how should I proceed for the main domain analytics. For some reason I cannot find the reccomended way to proceeds:

  1. Create a new GA property for the main domain
  2. Create a second WebApp on the Firebase Project and add that configuration to the main domain
  3. Add the same webapp configuration to both website.

The two website are obviously related. The main domain contains a description with a login button towards the app subdomain. The main objective I'd like to achieve is monitoring the traffic on my landing page and having the conversion/user acquisition trough that LOGIN button on the landing page.

Thank you in advance for your help and advices.

Here is the initialization code on https://app.teamspot.club home page:

<script>
    // Initialize Firebase
    var firebaseConfig = {
      apiKey: "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
      authDomain: "app.teamspot.club",
      projectId: "teamspot-00000",
      storageBucket: "teamspot-00000.appspot.com",
      messagingSenderId: "000000000000",
      appId: "1:00000000000:web:000000000000000000000",
      measurementId: "G-000000000"
    };
    firebase.initializeApp(firebaseConfig);
    const appCheck = firebase.appCheck();
    appCheck.activate(
      '6Lc0dU8cAAAAAK9dLPw-9WygTwOomYSZIQRcmdsI', true);
    firebase.analytics();
  </script>

I also linked the WebApp on Firebase to my Hosting website: enter image description here

0 Answers
Related