campoy / embedmd

embedmd: embed code into markdown and keep everything in sync
Apache License 2.0
767 stars 62 forks source link

Allow tabs to be rewritten to spaces #31

Closed joncalhoun closed 7 years ago

joncalhoun commented 7 years ago

Tabs work great in code because we can set their width to whatever we prefer in our editor, but in blog posts they usually just lead to code running off the screen.

It would be cool if you could translate tabs to 2 spaces, or set a tab width somehow. Is this a PR you would be willing to consider?

dmitshur commented 7 years ago

Can another tool do this? If so, that'd be better and more unix-y.

joncalhoun commented 7 years ago

@shurcooL Good point. It looks like https://github.com/revin/markdown-it-expand-tabs would do the trick and wouldn't be hard to rewrite in Go if someone didn't want to install Node.

Closing since this is unnecessary.