{"id":16399668,"url":"https://github.com/frantic1048/est","last_synced_at":"2025-03-23T05:31:05.859Z","repository":{"id":143749303,"uuid":"92438827","full_name":"frantic1048/Est","owner":"frantic1048","description":"[CONSTRUCTING] reStructuredText parser and renderer.","archived":false,"fork":false,"pushed_at":"2018-08-29T17:50:24.000Z","size":250,"stargazers_count":10,"open_issues_count":2,"forks_count":0,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-03-12T14:57:46.489Z","etag":null,"topics":["pegjs","resturcturedtext"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/frantic1048.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-05-25T19:49:17.000Z","updated_at":"2021-09-10T13:15:16.000Z","dependencies_parsed_at":"2023-07-25T17:32:02.075Z","dependency_job_id":null,"html_url":"https://github.com/frantic1048/Est","commit_stats":{"total_commits":97,"total_committers":2,"mean_commits":48.5,"dds":"0.17525773195876293","last_synced_commit":"3fcfd8d4a2d2930750776e7ff35e6b4839da5572"},"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frantic1048%2FEst","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frantic1048%2FEst/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frantic1048%2FEst/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frantic1048%2FEst/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/frantic1048","download_url":"https://codeload.github.com/frantic1048/Est/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245061382,"owners_count":20554563,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["pegjs","resturcturedtext"],"created_at":"2024-10-11T05:25:15.258Z","updated_at":"2025-03-23T05:31:05.502Z","avatar_url":"https://github.com/frantic1048.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"Est\n=========\n|license|_ |code quality|_ |ci|_ |dm|_\n\n.. |license| image:: https://img.shields.io/github/license/frantic1048/est.svg?style=flat-square\n.. _license: https://github.com/frantic1048/est/blob/master/LICENSE\n.. |code quality| image:: https://img.shields.io/codacy/grade/3aa60448106f4001b7ac194829f98397.svg?style=flat-square\n.. _`code quality`: https://www.codacy.com/app/frantic1048/Est/dashboard\n.. |ci| image:: https://img.shields.io/travis/frantic1048/Est.svg?style=flat-square\n.. _ci: https://travis-ci.org/frantic1048/Est\n.. |dm| image:: https://img.shields.io/david/frantic1048/Est.svg?style=flat-square\n.. _dm: https://david-dm.org/frantic1048/Est\n\nreStructuredText parser and renderer.\n\nInstall\n=========\n\nUse yarn to fetch the package, or npm if you prefer.\n\n.. code:: sh\n\n    yarn add @frantic1048/Est\n\n\nUsage\n=========\n\nAfter build:\n\n.. code:: js\n\n    // do not forget the ``@frantic1048`` scope\n    import est from '@frantic1048/Est'\n\n    // directly render rST into HTML string\n    const html = est.rst2html('reStructuredText string...')\n\n\n    // or...?\n    // welcome to the dark side...\n\n    // generate parsing tree\n    // which is an ASTy instance\n    const parse_t = est.parse('reStructuredText string...')\n\n    // transfrom parsing tree into doc tree\n    // which is an ASTy instance\n    const doc_t = est.transfrom(parse_t)\n\n    // render the doc tree into HTML string\n    const html_the_harder_way = est.render(doc_t)\n\nAll node types of the parsed tree can be found from ``est.TokenTypes`` .\n\n.. _ASTy: https://github.com/rse/asty\n\nThe node structure of a specific markup could be referred in ``test/grammar.\u003cMarkupName\u003e.js``\n\nRender function is under constructing.\n\nBuild\n=========\n\nPrepare:\n\n.. code:: sh\n\n    # fetch source code\n    git clone https://github.com/frantic1048/Est.git\n\n    # fetch dependencies\n    yarn\n\n\nBuild and run test:\n\n.. code:: sh\n\n    yarn ci\n\n\nProduction build:\n\n.. code:: sh\n\n    yarn dist\n\n\nDevelop:\n\n.. code:: sh\n\n    yarn dev\n\nThe build output is under ``lib`` folder. All possible files are:\n\n:est.dev.js: trace on, CommonJS module, debug and develop oriented.\n:est.min.js: trace off, single variable, Browser oriented.\n:est.js: trace off, CommonJS module, Node.js oriented.\n\nRecognized Markups\n==================\n\n:Inline:\n\n  - `emphasis \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#emphasis\u003e`_\n  - `strong emphasis \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#strong-emphasis\u003e`_\n  - `interpreted text \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#interpreted-text\u003e`_\n  - `inline literal \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#inline-literals\u003e`_\n  - `hyperlink reference \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#hyperlink-references\u003e`_\n  - `substitution reference \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#substitution-references\u003e`_\n  - `inline internal target \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#inline-internal-targets\u003e`_\n  - `standalone hyperlink \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#standalone-hyperlinks\u003e`_\n\n    URI is refer to `RFC 3986 \u003chttps://tools.ietf.org/html/rfc3986#appendix-A\u003e`_ 's ``absolute-URI`` definition, no scheme restriction.\n\n    Email address is a simplified subset of URI. See ``TextEmailAdress`` rule in ``src/parser.pegjs``\n\n\n:Block-level:\n\n  - `section \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#sections\u003e`_\n\n    Unlike adorment line should be longer than title text in spec, section adornment length \u003e 3 is accepted length.\n\n  - `transition \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#transitions\u003e`_\n  - `paragraph \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#paragraphs\u003e`_\n  - `bullet list \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#bullet-lists\u003e`_\n\n    fixed 2 spaces indent.\n\n  - `enumerated list \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#enumerated-lists\u003e`_\n\n    the text immediately after the enumerator determines the indentation (same as spec).\n\n  - `definition list \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#definition-lists\u003e`_\n\n    fixed 4 spaces indent.\n\n  - `field list \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#field-lists\u003e`_\n  - `option list \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#option-lists\u003e`_\n  - `footnote \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#footnotes\u003e`_\n\n    standalone hyperlink is not recognized in field name, while the other inline markups is recognized.\n\n  - `citation \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#citations\u003e`_\n  - `hyperlink target \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#hyperlink-targets\u003e`_\n  - `directive \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#directives\u003e`_\n  - `substitution definition \u003chttp://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#substitution-definitions\u003e`_\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrantic1048%2Fest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffrantic1048%2Fest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrantic1048%2Fest/lists"}