npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@ganttkit/vue

v0.2.0

Published

Vue 3 Gantt chart component for GanttKit - a <GanttChart> binding over the HTML, SVG or canvas renderer.

Readme

@ganttkit/vue

Vue 3 bindings for GanttKit.

This is a binding, not a fourth renderer. The chart is painted by one of the three base renderers - @ganttkit/html by default - and this package only owns that renderer's lifetime and wires it to Vue's reactivity. Every feature plugin (columns, tree, dependencies, markers, tooltip, selection, i18n, ...) works unchanged, because none of them know a framework is involved.

Install

pnpm add @ganttkit/vue @ganttkit/html @ganttkit/core

Usage

<script setup lang="ts">
import { ref } from 'vue'
import type { GanttRow, ViewMode } from '@ganttkit/core'
import { GanttChart } from '@ganttkit/vue'
import { createTree } from '@ganttkit/plugin-tree'
import '@ganttkit/vue/styles.css'

const rows: GanttRow[] = [
  { id: 'design', name: 'Design', tasks: [{ id: 't1', name: 'Wireframes', start: '2026-06-15', end: '2026-07-08' }] },
]
const plugins = [createTree().plugin]
const viewMode = ref<ViewMode>('Week')
</script>

<template>
  <GanttChart
    v-model:view-mode="viewMode"
    :rows="rows"
    :plugins="plugins"
    style="height: 70vh"
    @task-click="({ task }) => console.log(task.name)"
  />
</template>

The root element needs a height. Attributes (class, style, id) fall through to it, and the renderer adds its own gantt class on top.

Choosing a renderer

The chart is painted by @ganttkit/html unless you say otherwise. Pass renderer to paint with SVG or canvas instead, and import that package's stylesheet rather than @ganttkit/vue/styles.css:

<script setup lang="ts">
import { GanttChart } from '@ganttkit/vue'
import { canvasRenderer } from '@ganttkit/canvas'
import '@ganttkit/canvas/styles.css'
</script>

<template>
  <GanttChart :renderer="canvasRenderer" :rows="rows" style="height: 70vh" />
</template>

| Renderer | Package | Stylesheet | Paints each primitive as | | --- | --- | --- | --- | | htmlRenderer (default) | @ganttkit/html | @ganttkit/vue/styles.css | a positioned <div> | | svgRenderer | @ganttkit/svg | @ganttkit/svg/styles.css | an SVG element | | canvasRenderer | @ganttkit/canvas | @ganttkit/canvas/styles.css | a draw call on one 2D canvas |

@ganttkit/svg and @ganttkit/canvas are optional peers - install the one you use. @ganttkit/vue/styles.css re-exports the HTML sheet only, because it is the only renderer this package depends on; for the other two, import the stylesheet from the same package you import the renderer from.

Anything matching RendererFactory works, so a custom renderer drops in the same way:

import type { GanttPlugin, RendererOptions } from '@ganttkit/core'

const myRenderer = (options: RendererOptions): GanttPlugin => ({ ... })

renderer is a rebuild prop: swapping it tears the engine down and builds a fresh one with the new renderer.

Props

Every GanttOptions field, plus renderer, theme, enable-zoom, enable-pan, chevron and plugins.

They fall into three groups, which is the whole reactivity contract:

| Group | Props | Behaviour on change | | --- | --- | --- | | Live | rows, view-mode, theme, date-adapter | pushed into the running engine | | Rebuild | renderer, row-height, day-width, bar-padding, highlight-today, draggable, virtualize, overscan-rows, overscan-cols, start-date, end-date, enable-zoom, enable-pan | the engine is torn down and rebuilt | | Read once | plugins, chevron | read when the engine is built |

Because plugins is read once, an inline array is safe: it never causes a rebuild on its own.

Events

ready (the live GanttEngine), update:viewMode, task-click, task-dblclick, task-hover, task-hoverend, task-dragstart, task-dragmove, task-dragend, view-mode-change, date-range-change, rows-change, selection-change and row-toggle.

scene:change is deliberately not re-emitted - it fires on every scroll frame. Subscribe to it on the engine itself when you need it:

const chart = useTemplateRef('chart')
chart.value?.engine?.events.on('scene:change', ({ reason }) => { /* ... */ })

useGantt

For custom layouts, the composable behind the component is exported too. It owns an engine for the lifetime of the current scope and applies the same three-group contract:

const el = ref<HTMLElement | null>(null)
const { engine, rebuild } = useGantt(el, () => ({ rows: rows.value, viewMode: 'Week' }))

Examples

  • examples/basic - pnpm --filter @ganttkit/example-vue dev
  • examples/stress - large-dataset benchmark with a live metrics panel: pnpm --filter @ganttkit/example-vue-stress dev