Skip to content

Revisit Markd::Options class #54

@devnote-dev

Description

@devnote-dev

I think that there could be some changes/improvements to the current Options class:

  • Removing unimplemented options: given that they're not used, there's no actual reason to have them in the class – having a TODO comment or similar in place would be better for whomever wants to implement them
  • Removing time: I understand the purpose but this is really something that users could implement themselves if they wanted that information, and it's relatively easy to do
  • Replace safe: I like this option, but it is quite restricting – if you wanted to allow table HTML and nothing else, there would be no way to do that without performing string manipulation post-rendering. I think it would be better to change this into something like sanitize which gives you options on what HTML elements you want to allow, there is a sanitize shard that would be great for this
  • Rename prettyprint: (this one isn't important, but pretty_print makes so much more sense here lol)

WDYT?

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