{"id":33001907,"url":"https://github.com/ianho/xing-weapp-editor","last_synced_at":"2025-11-16T07:00:49.289Z","repository":{"id":147888166,"uuid":"144088359","full_name":"ianho/xing-weapp-editor","owner":"ianho","description":"开箱即用的微信小程序图文编辑组件","archived":false,"fork":false,"pushed_at":"2020-06-17T09:45:26.000Z","size":929,"stargazers_count":105,"open_issues_count":8,"forks_count":15,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-07-02T04:45:17.302Z","etag":null,"topics":["javascript","rich-text-editor","weapp","weixin"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ianho.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2018-08-09T01:55:24.000Z","updated_at":"2024-02-20T08:52:50.000Z","dependencies_parsed_at":"2023-05-27T20:00:33.728Z","dependency_job_id":null,"html_url":"https://github.com/ianho/xing-weapp-editor","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ianho/xing-weapp-editor","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ianho%2Fxing-weapp-editor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ianho%2Fxing-weapp-editor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ianho%2Fxing-weapp-editor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ianho%2Fxing-weapp-editor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ianho","download_url":"https://codeload.github.com/ianho/xing-weapp-editor/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ianho%2Fxing-weapp-editor/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":284672648,"owners_count":27044736,"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","status":"online","status_checked_at":"2025-11-16T02:00:05.974Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["javascript","rich-text-editor","weapp","weixin"],"created_at":"2025-11-13T14:00:24.545Z","updated_at":"2025-11-16T07:00:49.278Z","avatar_url":"https://github.com/ianho.png","language":"JavaScript","funding_links":[],"categories":["组件"],"sub_categories":[],"readme":"⚠️ 太久没空更新，不确定是否可用\n\n# xing-weapp-editor\n\n\u003e 开箱即用的小程序图文编辑组件\n\n## 代码片段\n\n[https://developers.weixin.qq.com/s/adp5u9mk7H6w](https://developers.weixin.qq.com/s/adp5u9mk7H6w)\n\n## 效果预览\n\n![](https://raw.githubusercontent.com/ianho/xing-weapp-editor/master/assets/editor.gif)\n\n## 组件属性\n\n属性名|类型|默认值|说明\n---|---|---|---\nimage-upload-url|String|无|图片上传，必填，参考[wx.uploadFile](https://developers.weixin.qq.com/miniprogram/dev/api/network-file.html#wxuploadfileobject)\nimage-upload-name|String|无|图片上传，必填，参考[wx.uploadFile](https://developers.weixin.qq.com/miniprogram/dev/api/network-file.html#wxuploadfileobject)\nimage-upload-header|String|无|图片上传，参考[wx.uploadFile](https://developers.weixin.qq.com/miniprogram/dev/api/network-file.html#wxuploadfileobject)\nimage-upload-form-data|Object|无|图片上传，参考[wx.uploadFile](https://developers.weixin.qq.com/miniprogram/dev/api/network-file.html#wxuploadfileobject)\nimage-upload-key-chain|String|无|图片上传接口返回值中url字段的路径，如返回为`{ image : { url: 'http://xxx.jpg' } }`，则填`image.url`\noutput-type|String|html|输出的格式，`html`或`array`，参考[rich-text](https://developers.weixin.qq.com/miniprogram/dev/component/rich-text.html)\nbutton-background-color|String|#409EFF|完成按钮的背景色\nbutton-text-color|String|#fff|完成按钮的前景色\nnodes|Array|无|初始内容的array形式，仅支持此组件输出的array，优先于HTML\nhtml|String|无|初始内容的HTML形式，仅支持此组件输出的HTML\nbindfinish|EventHandle|无|输出内容时触发，`event.detail = { content }`\n\n## 代码示例\n\n```xml\n\u003c!-- index.wxml --\u003e\n\u003cxing-editor\n  bindfinish=\"finish\"\n  output-type=\"html\"\n  image-upload-url=\"http://localhost:3000/upload\"\n  image-upload-name=\"image\"\n  image-upload-key-chain=\"image.url\"\n  html=\"{{html}}\"/\u003e\n```\n\n```javascript\n//index.js\nPage({\n  data: {\n    html: '\u003cp class=\"xing-p\"\u003e123124\u003cbr\u003e\u003cbr\u003e123124123\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e324123\u003c/p\u003e' +\n    '\u003cimg class=\"xing-img\" style=\"width: 100%\" src=\"http://localhost:3000/static/73e95bd90f005.png\" _height=\"0.5743348982785602\" _uploaded=\"true\"\u003e\u003c/img\u003e' +\n    '\u003cp class=\"xing-p\"\u003e333\u003c/p\u003e' +\n    '\u003cimg class=\"xing-img\" style=\"width: 100%\" src=\"http://localhost:3000/static/2dab4bd82f879.png\" _height=\"1.2095588235294117\" _uploaded=\"true\"\u003e\u003c/img\u003e',\n  },\n\n  finish: function (e) {\n    console.log(e.detail.content);\n  },\n})\n```\n\n```javascript\n{\n  \"usingComponents\": {\n    \"xing-editor\": \"/components/xing-editor\"\n  }\n}\n```\n\n## TODO List\n\n- □ 文字格式编辑\n- □ 图片免上传（转Base64存储）\n- □ 编辑预览\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fianho%2Fxing-weapp-editor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fianho%2Fxing-weapp-editor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fianho%2Fxing-weapp-editor/lists"}