I have javascript code in a page inside my AngularJS app which I need to send a scope variable to it, so I was wondering if that is possible in AngularJS and if yes, how? Thanks
index.html:
<script>
$(document).ready(function() {
var options = {
beforeSend: function(xhr){
xhr.setRequestHeader('Token', ###Need to pass scope var here### );
}
};
....
....
});
</script>
<div>
<p>
{{pageDescription}}
</p>
</div>
angular.element(elemWithinScope).scope().variableNameHere;