How to append base url to http requests in angular?



How to append base url to http requests in angular?..

Answer / Shyam

To append a base URL to HTTP requests in AngularJS, you can use the $httpProvider.defaults.baseURL property or create an interceptor that modifies the request configuration object before it is sent.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More AngularJS Interview Questions

What is cross site script inclusion (xssi)?

1 Answers  


Explain ng-include directive.

1 Answers  


How will you explain deep linking in angularjs?

1 Answers  


How to use foreach in angular js?

1 Answers  


What is difference between rootscope and scope in angular 2?

1 Answers  


Explain spa architecture in angularjs?

1 Answers  


What is shadow dom in angular?

1 Answers  


Explain what is angular expression? Explain what is the key difference between angular expressions and javascript expressions?

1 Answers  


How can I be lazy?

1 Answers  


How will you implement autorefresh in angularjs?

1 Answers  


Which are the core directives of angular js?

1 Answers  


Can you explain factory method in angularjs?

1 Answers  


Categories