search

Home  >  Q&A  >  body text

angular.js - angularjs interacting with backend

Using Angular as a front-end page, how to interact with the back-end (the back-end uses the Flask framework)? For example, how does the front end transmit data to the back end, and how does the back end get the data and transmit it to the front end?

为情所困为情所困2799 days ago648

reply all(2)I'll reply

  • phpcn_u1582

    phpcn_u15822017-05-15 17:02:15

    json format $http service

    reply
    0
  • 巴扎黑

    巴扎黑2017-05-15 17:02:15

    Usually inject $http service and interact with the background through get/post

    module.controller("YourCtrl", [$scope, $http,
        function(scope, http) {
        // your controller code here:
        }])

    reply
    0
  • Cancelreply