Skip to content
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

Swap out marked.js for markdown-it #604

Closed
miketaylr opened this issue Apr 6, 2015 · 9 comments
Closed

Swap out marked.js for markdown-it #604

miketaylr opened this issue Apr 6, 2015 · 9 comments

Comments

@miketaylr
Copy link
Member

See https://github.com/markdown-it/markdown-it. Actively maintained and has a plugin architecture. 👍

@miketaylr
Copy link
Member Author

TODO

investigate https://www.npmjs.com/package/markdown-it-hashtag as a hackable replacement for issue linking, or possibly https://www.npmjs.com/package/markdown-it-for-inline.

miketaylr pushed a commit that referenced this issue Apr 6, 2015
@miketaylr
Copy link
Member Author

Sweet, this markdown parser is already so much nicer.

miketaylr pushed a commit that referenced this issue Apr 6, 2015
miketaylr pushed a commit that referenced this issue Apr 6, 2015
miketaylr pushed a commit that referenced this issue Apr 6, 2015
miketaylr pushed a commit that referenced this issue Apr 6, 2015
miketaylr pushed a commit that referenced this issue Apr 6, 2015
@miketaylr
Copy link
Member Author

So the way this thing deals with emoji is to map to the real unicode emoji codepoint. So that leaves out some older browsers. See #260 (comment) for the plan on how I think we should proceed (tl;dr, if someone complains about lack of support in older browsers, we add in support for serving images).

@karlcow
Copy link
Member

karlcow commented Apr 6, 2015

So the way this thing deals with emoji is to map to the real unicode emoji codepoint.

Instant love. ;) I think it's fine to avoid image overload.
Talking about feature detections vs user agent sniffing. How do you detect in a code if you can send a unicode point or an image. :hurtrealbad:

@karlcow
Copy link
Member

karlcow commented Apr 6, 2015

Hmm i guess by testing if the value returns the generic character

String.fromCharCode(0x1F6C8) 

will return a generic icon for missing character (maybe different depending on the browsers).
hmmm…

@karlcow
Copy link
Member

karlcow commented Apr 6, 2015

holy 🐮 http://stimulus.hk/demos/testFont.html (Check the source code)

@miketaylr
Copy link
Member Author

I wonder if @mathiasbynens hasn't solved this problem before... (re: feature detection)

@mathiasbynens
Copy link

Well there’s https://github.com/Modernizr/Modernizr/blob/master/feature-detects/emoji.js which detects if an emoji renders as expected or not. You could do something similar for other characters.

Ah, that’s basically what http://stimulus.hk/demos/testFont.html (which @karlcow already mentioned) does. So there!

@miketaylr
Copy link
Member Author

thx!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants