Skip to content

Adding inline code and code block support #50

@sunknudsen

Description

@sunknudsen

Everything is converted except for <code>, <script>, <style>, and <pre> tags.

In the context of markdown strings, it would be amazing if inline code and code block snippets could be ignored (considering adding smartquotes to transpile-md-to-json.

const smartquotes = require("smartquotes");
 
const text = smartquotes("# The typography \"rabbit hole\"\n\nTo enter the rabbit's home, once must first enter the rabbit hole using command `enter \"rabbit hole\"`.\n\n```javascript\nconst rabbit = \"hole\"\n```");

console.log(text)

smartquotes

Current implementation breaks code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions