{"id":13671427,"url":"https://github.com/ioneday/wxchart","last_synced_at":"2025-04-27T18:31:15.501Z","repository":{"id":98061197,"uuid":"94441618","full_name":"ioneday/wxchart","owner":"ioneday","description":"微信小程序，图表组件（柱状图、折线图、饼图、雷达图...）。持续更新中...","archived":false,"fork":false,"pushed_at":"2017-06-16T09:54:55.000Z","size":111,"stargazers_count":91,"open_issues_count":6,"forks_count":32,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-11-11T09:43:41.989Z","etag":null,"topics":["chart","wechat"],"latest_commit_sha":null,"homepage":null,"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/ioneday.png","metadata":{"files":{"readme":"README.md","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}},"created_at":"2017-06-15T13:22:19.000Z","updated_at":"2024-09-25T04:43:50.000Z","dependencies_parsed_at":"2024-01-14T17:03:57.966Z","dependency_job_id":null,"html_url":"https://github.com/ioneday/wxchart","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ioneday%2Fwxchart","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ioneday%2Fwxchart/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ioneday%2Fwxchart/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ioneday%2Fwxchart/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ioneday","download_url":"https://codeload.github.com/ioneday/wxchart/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251187106,"owners_count":21549583,"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":["chart","wechat"],"created_at":"2024-08-02T09:01:09.481Z","updated_at":"2025-04-27T18:31:15.241Z","avatar_url":"https://github.com/ioneday.png","language":"JavaScript","readme":"# wxchart\n微信小程序，图表组件（柱状图、折线图、饼图、雷达图...）。持续更新中...\n\n\n\n![barchart](https://github.com/ioneday/wxchart/blob/master/image/barchart.png)![linechart](https://github.com/ioneday/wxchart/blob/master/image/line.png)![linechart](https://github.com/ioneday/wxchart/blob/master/image/barline.png)![linechart](https://github.com/ioneday/wxchart/blob/master/image/pie.png)\n\n\n\n\n\n### Useage\n\nwxml：\n\n```javascript\n//自适应屏幕宽度\n\u003ccanvas style=\"width:{{chartWidth}}px;height:{{chartHeight}}px;\"/\u003e\n```\n\njs：\n\n```javascript\nvar chart = require(\"../../utils/chart.js\");\n\nchart.draw(this, 'canvasId', {\n  hideYaxis: false,\n  color: ['#394655', '#74DAE5', '#ED7672', '#F3AA59', '#FEE746'],\n  title: {\n    text: \"2017城市人均收入(万)\",\n    color: \"#333333\",\n    size: 16\n  },\n  xAxis: {\n    color: \"#666A73\",\n    size: 10,\n    data: ['北京', '上海', '杭州', '深圳', '广州', '成都', '南京', '西安']\n  },\n  series: [\n    {\n          name: \"第一季度\",\n          category: \"bar\", //切换柱状图或折线图\n          data: [37, 63, 60, 78, 92, 63, 57, 48]\n        },\n        {\n          name: \"第二季度\",\n          category: \"line\",\n          data: [20, 35, 38, 59, 48, 27, 43, 35]\n        },\n        {\n          name: ['北京', '上海', '杭州', '深圳', '广州', '成都'],\n          category: \"pie\",//饼图不能与以上类型（bar、line）同时绘制\n          data: [40, 38, 39, 28, 27, 33]\n        }\n  ]\n});\n```\n\n\n\n\n\n","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fioneday%2Fwxchart","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fioneday%2Fwxchart","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fioneday%2Fwxchart/lists"}