How reference "Craft" js object in jquery scope I have this function within my &lt;script&gt; tags:

$('.btn').click(function()
{
    var data = {
        title: "This is a title"
    };

    Craft.postActionRequest('plugin/controller/action', data, function(response) {
    });
});


The "Craft" function returns as "TypeError: Craft is undefined". I'm guessing I somehow need to reference the scope to the function but I can't seem to get it to work.

I tried adding _self = this outside my jquery click function and reference Craft like "_self.Craft" but that didn't do it.

What am I missing here?
The "Craft" javascript global object can only be used in the backend, not on the frontend.