I've tasked myself with implementing a twitter clone in Ember.js in order to get more familiar with the framework. I've hit a bit of a snag however when it comes to implementing autolinking in the tweet.
There is an existing plugin that does external links (ex. http://www.google.com) well but doesn't work well for internal links (like @handle or #hashtags) which should as it should be implemented as a LinkComponent
but I can't figure out how to insert one from a helper.
source code: autolink helper (relevant unit test)
hosted site: link (use w_howard
/ secret
for login)
For now I have just had the helper insert a <a/>
tag but this sucks as it unloads the page and fetches everything fresh from the server.
Anyone have any suggestions about how best to implement this part of my Ember app?
Aucun commentaire:
Enregistrer un commentaire