{"id":20652144,"url":"https://github.com/skeyboy/vapormarkdown","last_synced_at":"2026-05-08T05:11:34.592Z","repository":{"id":87053113,"uuid":"155875885","full_name":"skeyboy/VaporMarkdown","owner":"skeyboy","description":"vapor leaf 模版引擎的Markdown标签","archived":false,"fork":false,"pushed_at":"2018-11-02T14:18:56.000Z","size":3,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-17T10:30:17.650Z","etag":null,"topics":["leaf","markdown","tag","vapor"],"latest_commit_sha":null,"homepage":null,"language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/skeyboy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2018-11-02T14:17:50.000Z","updated_at":"2018-11-02T14:19:54.000Z","dependencies_parsed_at":"2023-07-13T19:45:54.005Z","dependency_job_id":null,"html_url":"https://github.com/skeyboy/VaporMarkdown","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skeyboy%2FVaporMarkdown","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skeyboy%2FVaporMarkdown/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skeyboy%2FVaporMarkdown/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skeyboy%2FVaporMarkdown/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/skeyboy","download_url":"https://codeload.github.com/skeyboy/VaporMarkdown/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242751346,"owners_count":20179344,"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":["leaf","markdown","tag","vapor"],"created_at":"2024-11-16T17:32:41.141Z","updated_at":"2026-05-08T05:11:29.532Z","avatar_url":"https://github.com/skeyboy.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# VaporMarkdown\n\nvapor [leaf](https://github.com/vapor/leaf.git) 模版引擎的Markdown标签\n\n\u003e1 SPM引入\n```\n.package(url: \"https://github.com/skeyboy/VaporMarkdown.git\", from: \"0.0.1\"),\n```\n\u003e2 注册标签\n\n```\nservices.register { (Container) -\u003e (LeafTagConfig) in\nvar tagConfig = LeafTagConfig.default()\ntagConfig.use( VaporMarkdown.init(), as: \"markdown\")\nreturn tagConfig\n}\n```\n\u003e3 使用 markdown.leaf\n```\nlet msg = \"\"\"\n# 我是一个markdown\n## 我是一个副标题\n\u003e 我是一个引用\n\"\"\"\n\n#markdown(msg)\n\n```\n\u003e4 简单测试用例\n```\n func testMarkdown(){\n        let markdown = \"#markdown(h1)\"\n        let data = TemplateData.dictionary([\"h1\":.string(\"# woshi\")])\n        \n        let result = try! renderer.testRender(markdown, data)\n        \n        print(result)\n        XCTAssertEqual(\"\u003ch1\u003ewoshi\u003c/h1\u003e\\n\", result)\n    }\n```\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskeyboy%2Fvapormarkdown","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fskeyboy%2Fvapormarkdown","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskeyboy%2Fvapormarkdown/lists"}