If you are using an angular generator, you need two elements:
1 / Let your PHP work, as usual, in a type subdirectory public, so it public/index.phploads when you go tohttp://localhost/
2/ Grunt AngularJS src - public/js/myapp.js public/index.php - <script src="/js/myapp.js></script>
3/ JSON angular, json_encode, :
<?php
header('Content-type: application/json');
echo json_encode($someArray); ?>
?>
grunt-php PHP dev-.
- , AngularJS FlightPHP: https://npmjs.org/package/generator-flightangular - , JavaScript PHP.