Skip to content

Instantly share code, notes, and snippets.


Chris Hopewell (Leeka) J-who

View GitHub Profile
rishabhmhjn / tweetLinky.js
Last active Jun 5, 2020
This is an AngularJS filter to linkify #hashtags and @mention texts into respective Twitter URLsDemo -
View tweetLinky.js
var app = angular.module('tLinky', ['ngSanitize']);
app.filter('tweetLinky',['$filter', '$sce',
function($filter, $sce) {
return function(text, target) {
if (!text) return text;
var replacedText = $filter('linky')(text, target);
var targetAttr = "";
if (angular.isDefined(target)) {