KLineChart
📈Lightweight k-line chart that can be highly customized. Zero dependencies. Support mobile.(可高度自定义的轻量级k线图,无第三方依赖,支持移动端)
**KLineChart** is a 📈Lightweight k-line chart that can be highly customized. Zero dependencies. Support mobile.(可高度自定义的轻量级k线图,无第三方依赖,支持移动端) The project is written primarily in TypeScript, distributed under the Apache License 2.0 license, first published in 2019. It has gained significant community traction with 3,871 stars and 948 forks on GitHub. Key topics include: candlestick, canvas, chart, exchange, finance.
✨ Features
- 📦 Out of the box: Simple and fast integration, basically zero cost to get started.
- 🚀 Lightweight and smooth: Zero dependencies, only 40k under gzip compression.
- 💪 Powerful functions: Built-in multiple indicators and line drawing models.
- 🎨 Highly scalable: With rich style configuration and API, the function can be extended as you like.
- 📱 Mobile: Support mobile, one chart, handle multiple terminals.
- 🛡 Typescript development: Provide complete type definition files.
📦 Install
Using npm
bashnpm install klinecharts --save
Using yarn
bashyarn add klinecharts
CDNs
unpkg
html<script type="text/javascript" src="https://unpkg.com/klinecharts/dist/klinecharts.min.js"></script>
jsDelivr
html<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/klinecharts/dist/klinecharts.min.js"></script>
📄 Docs
Online
Locale
Execute command in root directory. Node.js is required.
bash# Install the dependencies npm install # Start document service npm run docs:dev
After successful startup, open in the browser http://localhost:8888 .
🛠️ Build
Execute command in root directory. Node.js is required.
bash# Install the dependencies npm install # Build files npm run build
The generated files are in the dist folder.
🔗 Links
- KLineChart Preview: A more complete example.
- KLineChart Pro: Financial chart built out of the box based on KLineChart.
- openctp: Trading simulation environment for the Chinese market.
©️ License
KLineChart is available under the Apache License V2.
Contributors
Showing top 12 contributors by commit count.
