Compiles a piece of HTML or DOM into a scope object.
scope
var scope1 = angular.compile(window.document); scope1.$init(); var scope2 = angular.compile('click me'); scope2.$init();