$compile将js生成的HTML中注入$scope,那样就可以在生成的HTML中使用angular
var maphtml = $('#allmap1');
$compile(maphtml)($scope);
$compile将js生成的HTML中注入$scope,那样就可以在生成的HTML中使用angular
var maphtml = $('#allmap1');
$compile(maphtml)($scope);
转载于:https://www.cnblogs.com/cacti/p/8427231.html