openTab = function () {
$http.post(\'www.google.com\');
}
>
Proper HTML way: just surround your button with anchor element and add attribute target="_blank". It is as simple as that:
Open me in new Tab
where you can set in the controller:
$scope.yourDynamicURL = 'https://stackoverflow.com';