Skip to content

Instantly share code, notes, and snippets.

@shangoyanyi
Last active November 2, 2015 05:44
Show Gist options
  • Save shangoyanyi/f9fba69f3474e53d25c7 to your computer and use it in GitHub Desktop.
Save shangoyanyi/f9fba69f3474e53d25c7 to your computer and use it in GitHub Desktop.
Angular - fix the security issue of iframe src
/**
* use $sce.trustAsResourceUrl(SOME_URL) to fix the security issue
*/
$scope.videoUrl = $sce.trustAsResourceUrl(recipe.get("video").url);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment