-
Notifications
You must be signed in to change notification settings - Fork 334
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added Twitter link to the auto links section #105
Conversation
Hmm, this is interesting. We're moving to @chjj 's Marked in the very soon to be released beta because showdown is terrible, but I kinda like this idea. @johnmdonahue How do you feel about this but doing it in Marked somehow? |
I like this idea, but maybe as an extension rather than core. I am thinking of situations where this may cause unexpected outcomes for users not intending to point to Twitter. Say I want to write the following: ## Contact
My handle is @foomanchu pretty much everywhere except on twitter where I'm @foobazzchu. This seems like a perfect candidate for an extension but |
BTW. It looks like a similar request was brought up in Marked as well: markedjs/marked#44 |
@johnmdonahue, just to let everyone know, I leave a lot of issues open because I want to be challenged on my opinion. Even if it looks like I've decided on an issue, I probably haven't. I just have strong opinions on it. |
@johnmdonahue I'm a fan these type of rules being extensions rather than part of the core. Keep the core clean and simple and provide a point to add additional rules. The point about the In the grand scheme I think that twitter (almost, perhaps) owns the Still an extension is called for and not part of the core syntax. |
@OscarGodson do you plan on having Marked as a client-side requirement or will you bundle it together with EpicEditor similar to how you have with Showdown? |
I like the idea of the extension. The extension would allow you to pick the domain to add it to as well, something like:
I'm going to keep this pull request open as a stub for this extension. |
@roberocity Once the extension stuff is done it's going to be pulled out and will be added as a "parser extension". For the beta coming (0.1.x) it'll be bundled. Or, this is what we've had planned. |
Now there's a parser option so you could do this in that. |
I have stated a markdown flavour with a mix of markdown and twitter markup here: https://github.com/eckoit/bird-down I am currently using it with epic editor successfully, using the custom parser, see here for an example usage: |
Awesome! Always glad to see what people are doing with EpicEditor :) |
Oh also, if you haven't already, add your script to the EpicEditor Implementations page in the wiki! |
Will convert
@username to
<a target="blank" href="http://twitter.com/username">@username</a>
just like it works for email addresses and other basic URL patterns.