{"name":"@antv/g2","version":"3.4.9","description":"the Grammar of Graphics in Javascript","browser":"build/g2.js","main":"build/g2.js","module":"lib/index.js","types":"lib/index.d.ts","homepage":"https://github.com/antvis/g2","repository":{"type":"git","url":"git+ssh://git@github.com/antvis/g2.git"},"bugs":{"url":"https://github.com/antvis/g2/issues"},"keywords":["g2","chart"],"author":{"name":"https://github.com/orgs/antvis/people"},"license":"MIT","devDependencies":{"@antv/data-set":"~0.9.6","@babel/cli":"~7.0.0","@babel/core":"~7.0.0","@babel/preset-env":"~7.0.0","babel-eslint":"~8.0.3","babel-loader":"~8.0.0","babel-plugin-transform-remove-strict-mode":"~0.0.2","blink-diff":"^1.0.13","body-parser":"~1.18.2","chai":"~4.1.2","commander":"~2.12.2","connect":"~3.6.6","d3-queue":"~3.0.7","debug":"~3.1.0","electron":"~1.8.7","eslint":"~3.19.0","eslint-config-airbnb":"~15.0.1","eslint-config-egg":"~4.2.0","eslint-plugin-html":"~3.1.1","eslint-plugin-jsx-a11y":"~5.1.1","eslint-plugin-react":"~7.1.0","event-simulate":"~1.0.0","get-port":"~3.2.0","jszip":"~3.1.5","nightmare":"~2.10.0","nunjucks":"~3.0.1","open":"~0.0.5","parseurl":"~1.3.2","pre-commit":"~1.2.2","serve-static":"~1.13.2","shelljs":"~0.7.8","torchjs":"~2.1.0","tslint":"~5.10.0","typescript":"~2.9.2","uglify-js":"~3.1.10","webpack":"~3.10.0"},"scripts":{"build":"webpack","build-lib":"babel src --out-dir lib && cp src/index.d.ts lib/","bundler":"electron ./bundler/app.js","ci":"npm run lint && npm run test","compress-g2":"uglifyjs -c -m -o dist/g2.min.js -- build/g2.js","compress-core":"uglifyjs -c -m -o dist/g2-core.min.js -- build/g2-core.js","compress-simple":"uglifyjs -c -m -o dist/g2-simple.min.js -- build/g2-simple.js","compress":"npm run compress-g2 && npm run compress-core && npm run compress-simple","coverage":"npm run coverage-generator && npm run coverage-viewer","coverage-generator":"torch --compile --coverage --renderer --recursive --source-pattern src/*.js,src/**/*.js test/unit","coverage-viewer":"torch-coverage","demos":"electron ./demos/app.js","demos-web":"node ./demos/app.js --web --port 2046","dev":"npm run watch & npm run demos-web","dist":"npm run mkdir-dist && npm run build && npm run compress","lint":"eslint --ext .html,.js ./","lint-fix":"eslint --ext .html,.js --fix ./","mkdir-dist":"node ./bin/mkdir-dist.js","prepublishOnly":"npm run build-lib && npm run dist","pixel-test":"node ./bin/pixel-test.js","screenshot":"node ./bin/screenshot.js","start":"npm run dev","test":"torch --compile --renderer --recursive ./test/unit","test-all":"npm run test && npm run test-bugs","test-bugs":"torch --compile --renderer --recursive ./test/bugs","test-bugs-live":"torch --compile --interactive --watch --recursive ./test/bugs","test-live":"torch --compile --interactive --watch --recursive ./test/unit","tslint":"tslint --project tsconfig.json --config tslint.json src/index.d.ts","watch":"webpack --config webpack-dev.config.js","win-dev":"node ./bin/win-dev.js"},"pre-commit":{"run":["lint","test-all"],"silent":false},"dependencies":{"@antv/component":"~0.3.1","@antv/adjust":"~0.1.0","@antv/attr":"~0.1.2","@antv/coord":"~0.1.0","@antv/g":"~3.3.5","@antv/scale":"~0.1.0","@antv/util":"~1.3.1","venn.js":"~0.2.20","wolfy87-eventemitter":"~5.1.0"},"gitHead":"d63c654b200973eb54814d57c994f9d1d24c40b5","_id":"@antv/g2@3.4.9","_npmVersion":"6.5.0","_nodeVersion":"8.11.4","_npmUser":{"name":"leungwensen","email":"leungwensen@gmail.com"},"dist":{"integrity":"sha512-SVGJlnkUT+WP6nHvSNBnu+8LwyQaMzzY8RCEkA+c0XqblJXEIrqbbgLKcI2Y0/3o+uPRccwRAQyFJ8b0DKfIZA==","shasum":"8e8d090372e9aa8481ec902dc93dbcdcb5899232","tarball":"http://registry-npm.ywwl.com/@antv/g2/download/@antv/g2-3.4.9.tgz","fileCount":227,"unpackedSize":11064142,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcL0zxCRA9TVsSAnZWagAALhAQAJJUxbTW9A1TisnX17HX\nQZrq2SbWRd4XvaVITuTqKysfzgbubtJc0uVKl8tOaT5WGboeh5SjHrZ2Wzs7\nl/lWtAjEz/lBw8PQL7xFSp0yMrj+/Xdq8WFIL5iuOZPFTdLEJ+ZWIWORn8El\nWdpB8iylIcRffSMBAZ2G8MtQbNYyRouVBNvSvwMInNLbH/M9gGGVLmhq6Ywo\nP+iWizn7VamVVWZ2T5KZi221Jrd/lo8zctMLnJ2Fg8uyDdwL0coI4DzIvPRZ\n9sqdWBMi2vljQ2/+b2DIV1UAdILsGLGyUyy5ue0XdTeDMRMDFFPJrM92ziqb\n6SUfABVgXFYphIeBnQ5yVEidDcEuK+mvEsA5Nw+EWGrKHmqd+AZRv46XgpGl\nbCj+wF+W41SAdGX7XvEB8aVynvw6jSV7K1EBJmQLx6mUCF/zYsMBxMNNqQBp\nxOexvSM4crZm8chmtboX4CP/jARMR+FUDAiJT21ovwDHap+EISTU/9Xl1yI6\nSdEbnPxUigO3a+CprXAr9WpBH/xGOXiwv3XGPB8jy2EjnQoklOuA5FNx6p+F\nHom+U77atSSxkwxCquZ705EYVrKdyD2bCYuA2Sv4vahhQRCsBvW5Mrzkuflz\nGEL3yYNf2cRgJSueKaz70WXzjV/JT6FnC06QUb3on0b2E/0LUayUwMsKtOSZ\n5MC8\r\n=Kk9S\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDj+eNdOffI6JeUN5ZKFDoY87FrS0tY+ewY1aWmHLxynAiEAhtVdZc89OzvIaF+priDGtO1aVU9poXmInY2aP3jKh3I="}],"size":2361133,"noattachment":false,"key":"/@antv/g2/-/@antv/g2-3.4.9.tgz"},"maintainers":[{"email":"418466938@qq.com","name":"dori"},{"email":"dxq613@gmail.com","name":"dxq613"},{"email":"yilin.qyl@antfin.com","name":"elaine.q.10"},{"email":"leungwensen@gmail.com","name":"leungwensen"},{"email":"120635640@qq.com","name":"lzxue"},{"email":"360965398@qq.com","name":"sakuya223"},{"email":"sima.zhang1990@gmail.com","name":"simaq"},{"email":"yanyanwang93@gmail.com","name":"yanyan-wang"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/g2_3.4.9_1546603761140_0.5807173699785488"},"_hasShrinkwrap":false,"readme":"<img src=\"https://gw.alipayobjects.com/zos/antfincdn/R8sN%24GNdh6/language.svg\" width=\"18\"> [English](./README.md) | 简体中文\n\n<h1 align=\"center\">\n<b>G2 5.0</b>\n</h1>\n\n<div align=\"center\">\n\n简洁的渐进式可视化语法，用于构建仪表盘、数据探索以及数据讲故事。\n\n<p align=\"center\">\n  <a href=\"https://g2.antv.antgroup.com/manual/introduction/what-is-g2\">介绍</a> •\n  <a href=\"https://g2.antv.antgroup.com/examples\">案例</a> •\n  <a href=\"https://g2.antv.antgroup.com/manual/introduction/getting-started\">教程</a> •\n  <a href=\"https://g2.antv.antgroup.com/api/overview\">API</a>\n</p>\n\n[![Build Status](https://github.com/antvis/g2/workflows/build/badge.svg?branch=v5)](https://github.com/antvis//actions)\n[![Coverage Status](https://img.shields.io/coveralls/github/antvis/g2/v5.svg)](https://coveralls.io/github/antvis/g2?branch=v5)\n[![npm Version](https://img.shields.io/npm/v/@antv/g2.svg)](https://www.npmjs.com/package/@antv/g2)\n[![npm Download](https://img.shields.io/npm/dm/@antv/g2.svg)](https://www.npmjs.com/package/@antv/g2)\n[![npm License](https://img.shields.io/npm/l/@antv/g2.svg)](https://www.npmjs.com/package/@antv/g2)\n\n![examples](https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*_GfqQoRCqQkAAAAAAAAAAAAADmJ7AQ/fmt.webp)\n\n</div>\n\nG2 起源于 Leland Wilkinson 的图形语法：《The Grammar of Graphics》，但又不止于图形语法。\n\n## ✨ 特色\n\n- **渐进式语法**：结合工业和学术实践，实现图形语法、动画语法和交互语法。\n- **丰富的标记**：内置 10+ 基础标记，8+ 高阶标记。\n- **高可扩展性**：提供统一机制扩展所有可视化组件。\n- **个性化风格**：支持手绘、圆角、纹理等风格。\n- **多环境渲染**：支持 Canvas、SVG 以及 WebGL，和 Node.js 服务端渲染。\n\n## 🔨 开始使用\n\n可以通过 NPM 或 Yarn 等包管理器来安装。\n\n```bash\n$ npm install @antv/g2\n```\n\n```bash\n$ yarn add @antv/g2\n```\n\n成功安装之后，可以通过 import 导入 Chart 对象。\n\n```html\n<div id=\"container\"></div>\n```\n\n```js\nimport { Chart } from '@antv/g2';\n\n// 准备数据\nconst data = [\n  { genre: 'Sports', sold: 275 },\n  { genre: 'Strategy', sold: 115 },\n  { genre: 'Action', sold: 120 },\n  { genre: 'Shooter', sold: 350 },\n  { genre: 'Other', sold: 150 },\n];\n\n// 初始化图表实例\nconst chart = new Chart({\n  container: 'container',\n});\n\n// 声明可视化\nchart\n  .interval()                 // 创建一个 Interval 标记\n  .data(data)                 // 绑定数据\n  .encode('x', 'genre')       // 编码 x 通道\n  .encode('y', 'sold')        // 编码 y 通道\n  .encode('color', 'genre');  // 编码 color 通道\n\n// 渲染可视化\nchart.render();\n```\n\n如果一切顺利，你可以得到下面的柱状图!\n\n<img src=\"https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*XqCnTbkpAkQAAAAAAAAAAAAADmJ7AQ/fmt.webp\" width=\"640\" alt=\"example\">\n\n## 🌍 生态\n\n- [g2-react](https://github.com/pearmini/g2-react) - G2 的轻量级 React 组件，没有额外特性。\n- [g2-extensions](https://github.com/antvis/g2-extensions) - G2 的一系列插件库，包含 3D 和智能可视化等。\n- [ant-design-charts](https://github.com/ant-design/ant-design-charts) - React 图表库，基于 [G2](https://github.com/antvis/G2), [G6](https://github.com/antvis/G6), [X6](https://github.com/antvis/X6), [L7Plot](https://github.com/antvis/L7Plot).\n- [更多...](https://github.com/antvis/G2/discussions/5772)\n\n## 📮 参与贡献\n\n- [问题](https://github.com/antvis/g2/issues)： 报告 bug 或者提出需求\n- [贡献指南](https://github.com/antvis/g2/blob/v5/CONTRIBUTING.zh-CN.md)：参与建设 G2\n- [讨论](https://github.com/antvis/G2/discussions)：在 GitHub 上或者钉钉群里面讨论（30233731, 35686967, 44788198）\n\n<img src=\"https://gw.alipayobjects.com/zos/antfincdn/hTzzaqgHgQ/Antv%252520G2%252520%26%252520G2Plot.png\" width=\"200\" height=\"266\" alt=\"code\"/>\n\n## 📄 许可证\n\nMIT@[AntV](https://github.com/antvis).\n","publish_time":1546603761341,"_cnpm_publish_time":1546603761341,"dist-tags":{"alpha":"5.3.4-alpha.0","beta":"5.3.6-beta.4","latest":"5.4.8","v3-latest":"3.5.19"}}