cs0117 error in infinite platform script

HI i’m new in unity

I’m trying to make a infinite platform script but I got the following error for this script:

error CS0117: UnityEngine.GameObject' does not contain a definition for GetComponnent’

using UnityEngine;
using System.Collections;

public class test : MonoBehaviour {

public GameObject thePlatform;
public Transform generationPoint;
public float distanceBetween;

private float platformWidth;

// Use this for initialization
void Start () {
    platformWidth = thePlatform.GetComponnent<BoxCollider2D>().size.x;

}

// Update is called once per frame
void Update () {

}
 }

I don’t understand why i got this error and how can i fix-it?

can you help me guys?

thank for your time

“GetComponnent” is a typographical error. The actual function you are trying to use is “GetComponent”.

I alsaw get this error…
error CS1061: Type UnityEngine.GameObject' does not contain a definition for GetComponnent’ and no extension method GetComponnent' of type UnityEngine.GameObject’ could be found (are you missing a using directive or an assembly reference?