你可以使用html&在标签标题中点按,例如
原文链接:https://www.f2er.com/angularjs/141698.html<div ng-controller="mainCtrl"> <tabset> <tab ng-repeat="t in tabs"> <tab-heading>{{t.title}} <a ng-click="removeTab($index)" href=''><i class="icon-remove"></i></a></tab-heading> <div ng-bind-html-unsafe='t.content'></div> </tab> </tabset> </div> angular.module('myApp',['ui.bootstrap']).controller("mainCtrl",function ($scope) { $scope.tabs = [{ title: "one",content: '<h1>tab one</h1>' },{ title: "two",content: '<h1>tab two</h1>' },{ title: "three",content: '<h1>tab three</h1>' }]; $scope.removeTab = function (index) { $scope.tabs.splice(index,1); }; });