{"action":"created","issue":{"url":"https://api.github.com/repos/cebe/markdown/issues/55","repository_url":"https://api.github.com/repos/cebe/markdown","labels_url":"https://api.github.com/repos/cebe/markdown/issues/55/labels{/name}","comments_url":"https://api.github.com/repos/cebe/markdown/issues/55/comments","events_url":"https://api.github.com/repos/cebe/markdown/issues/55/events","html_url":"https://github.com/cebe/markdown/issues/55","id":39616514,"number":55,"title":"Custom tags/extensions","user":{"login":"dolfinitylearning","id":775637,"avatar_url":"https://avatars3.githubusercontent.com/u/775637?v=4","gravatar_id":"","url":"https://api.github.com/users/dolfinitylearning","html_url":"https://github.com/dolfinitylearning","followers_url":"https://api.github.com/users/dolfinitylearning/followers","following_url":"https://api.github.com/users/dolfinitylearning/following{/other_user}","gists_url":"https://api.github.com/users/dolfinitylearning/gists{/gist_id}","starred_url":"https://api.github.com/users/dolfinitylearning/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dolfinitylearning/subscriptions","organizations_url":"https://api.github.com/users/dolfinitylearning/orgs","repos_url":"https://api.github.com/users/dolfinitylearning/repos","events_url":"https://api.github.com/users/dolfinitylearning/events{/privacy}","received_events_url":"https://api.github.com/users/dolfinitylearning/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2014-08-06T12:35:12Z","updated_at":"2018-03-14T20:35:11Z","closed_at":"2018-03-14T20:35:11Z","author_association":"NONE","body":"A nice thing about ReST is its standard for adding custom directives. Would such a thing be useful in cebe/markdown?\n\nKramdown does this:\n\n{::comment}\nThis is a comment which is\ncompletely ignored.\n{:/comment}\n\nInline {::nomarkdown}something here{:/}!\n\n{::options auto_ids=\"false\" /}\n\nAn alternative:\n\n@tag arg arg\ncontent content content\n\ncontent content content\n/@tag\n\nDocutils (the lib with the ReST parser) has a nice Directive class that does some of the parsing for dumb bunnies like me. For example:\n\n``` python\nclass Exercise(Directive):\n    has_content = False\n    required_arguments = 1\n\n    def run(self):\n        result = '[[[cycoexercise:' + self.arguments[0] + ']]]\\n'\n        raw_node = nodes.raw('', result, format='html')\n        return [raw_node]\n```\n\nGiven a tag like this...\n\n.. exercise:: 666\n\n... the Directive class would pick out the 666 and supply it to the subclass in `self.arguments`. If the tag has content, it shows up in `self.content`. You can do this...\n\n``` python\n        self.state.nested_parse(\n            self.content,\n            self.content_offset,\n            content_node\n        )\n```\n\n... if the content of the custom tag is to contain ReST. \n\nAny chance of something like this?\n\nKieran\n"},"comment":{"url":"https://api.github.com/repos/cebe/markdown/issues/comments/373165506","html_url":"https://github.com/cebe/markdown/issues/55#issuecomment-373165506","issue_url":"https://api.github.com/repos/cebe/markdown/issues/55","id":373165506,"user":{"login":"cebe","id":189796,"avatar_url":"https://avatars0.githubusercontent.com/u/189796?v=4","gravatar_id":"","url":"https://api.github.com/users/cebe","html_url":"https://github.com/cebe","followers_url":"https://api.github.com/users/cebe/followers","following_url":"https://api.github.com/users/cebe/following{/other_user}","gists_url":"https://api.github.com/users/cebe/gists{/gist_id}","starred_url":"https://api.github.com/users/cebe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cebe/subscriptions","organizations_url":"https://api.github.com/users/cebe/orgs","repos_url":"https://api.github.com/users/cebe/repos","events_url":"https://api.github.com/users/cebe/events{/privacy}","received_events_url":"https://api.github.com/users/cebe/received_events","type":"User","site_admin":false},"created_at":"2018-03-14T20:35:11Z","updated_at":"2018-03-14T20:35:11Z","author_association":"OWNER","body":"I read the issue twice but I do not understand what to do with it. This library implements markdown parsing using extisting standards, I am not going to develop new markdown syntax. That is possible in your own application or library by extending the classes provided by this library."}}
{"actor":{"display_login":"cebe"}}