Area
There is no type area. A filled line is type line with mark.area. Several series that add up are stacked-area.
Import@chartkitdev/core/charts/lineBundle@chartkitdev/core/allSpec typelineFamilyCore
Spec
Filled line. The spec type is line, with mark.area.
npm install @chartkitdev/core
npm install @chartkitdev/react
import { Chart } from "@chartkitdev/react";
export function Panel() {
return <Chart spec={spec} />;
}npm install @chartkitdev/core
npm install @chartkitdev/vanilla
import { mount } from "@chartkitdev/vanilla";
const chart = mount(document.querySelector("#chart"), spec);
chart.update(spec);npm install @chartkitdev/core
npm install @chartkitdev/vue
<script setup>
import { Chart } from "@chartkitdev/vue";
</script>
<template>
<Chart :spec="spec" />
</template>npm install @chartkitdev/core
npm install @chartkitdev/svelte
<script>
import { Chart } from "@chartkitdev/svelte";
</script>
<Chart {spec} />npm install @chartkitdev/core
npm install @chartkitdev/astro
---
import { Chart } from "@chartkitdev/astro";
---
<Chart spec={spec} />npm install @chartkitdev/core
npm install @chartkitdev/solid
import { Chart } from "@chartkitdev/solid";
export function Panel() {
return <Chart spec={spec} />;
}npm install @chartkitdev/core
npm install @chartkitdev/qwik
import { component$ } from "@builder.io/qwik";
import { Chart } from "@chartkitdev/qwik";
export const Panel = component$(() => {
return <Chart spec={spec} />;
});npm install @chartkitdev/core
npm install @chartkitdev/angular
import { Component } from "@angular/core";
import { Chart } from "@chartkitdev/angular";
@Component({
standalone: true,
imports: [Chart],
template: `<ck-chart [spec]="spec" />`,
})
export class Panel {
spec = spec;
}npm install @chartkitdev/core
npm install @chartkitdev/element
import "@chartkitdev/element";
const chart = document.querySelector("chart-kit");
chart.spec = spec;Anatomy
- The spec on this page is type line with mark.area true.
- encoding.y.area fills one channel and leaves the others as lines.
- stacked-area is the chart for parts of a whole over an ordered x.
Options that apply
| Path | Role | Status |
|---|---|---|
| The spec on this page is type line with mark.area true. | Current docs | in the library |
| encoding.y.area fills one channel and leaves the others as lines. | Current docs | in the library |
| stacked-area is the chart for parts of a whole over an ordered x. | Current docs | in the library |
Not a separate type
The v1 schema has line and stacked-area. It does not have area. This URL is the docs-nav name for a filled line.
Examples
A filled line is type: "line" with mark.area. Worked examples are on Line and Stacked area.