Vue Pivottable (Vue2)Vue Pivottable (Vue2)
  • Introduction
  • Getting Started
  • Locale
  • Slot
  • Scoped Slot
  • Utilities
  • Renderer
  • Props Reference
  • Styling
  • v1.x (Vue 3)
Contribute πŸ’š
  • English
  • ν•œκ΅­μ–΄
GitHub
  • Introduction
  • Getting Started
  • Locale
  • Slot
  • Scoped Slot
  • Utilities
  • Renderer
  • Props Reference
  • Styling
  • v1.x (Vue 3)
Contribute πŸ’š
  • English
  • ν•œκ΅­μ–΄
GitHub
  • Guide

    • Introduction
    • Getting Started
  • Advanced

    • Locale
    • Slot
    • Scoped Slot
    • Utilities
    • Renderer
  • Props
  • Styling

Locale

How to use?

The default locales is defined in /src/helper/utils.js .

const locales = {
  en: {
    aggregators,
    localeStrings: {
      renderError: 'An error occurred rendering the PivotTable results.',
      computeError: 'An error occurred computing the PivotTable results.',
      uiRenderError: 'An error occurred rendering the PivotTable UI.',
      selectAll: 'Select All',
      selectNone: 'Select None',
      tooMany: '(too many to list)',
      filterResults: 'Filter values',
      totals: 'Totals',
      vs: 'vs',
      by: 'by'
    }
  }
}
export {
  locales
}

If you want to add a new language add both locale and locales props.

import { PivotUtilities } from "vue-pivottable";

const locales = {
  en: PivotUtilities.locales.en,
  ko: {
    aggregators: PivotUtilities.aggregators,
    localeStrings: {
      renderError:
        "ν”Όλ²— ν…Œμ΄λΈ” κ²°κ³Όλ₯Ό λ Œλ”λ§ν•˜λŠ” λ™μ•ˆ 였λ₯˜κ°€ λ°œμƒ ν–ˆμŠ΅λ‹ˆλ‹€.",
      computeError:
        "ν”Όλ²— ν…Œμ΄λΈ” κ²°κ³Όλ₯Ό κ³„μ‚°ν•˜λŠ” λ™μ•ˆ 였λ₯˜κ°€ λ°œμƒ ν–ˆμŠ΅λ‹ˆλ‹€.",
      uiRenderError:
        "ν”Όλ²— ν…Œμ΄λΈ” UIλ₯Ό λ Œλ”λ§ν•˜λŠ” λ™μ•ˆ 였λ₯˜κ°€ λ°œμƒ ν–ˆμŠ΅λ‹ˆλ‹€.",
      selectAll: "λͺ¨λ‘ 선택",
      selectNone: "선택 μ•ˆν•¨",
      tooMany: "ν‘œμ‹œ ν•  값이 λ„ˆλ¬΄ λ§ŽμŠ΅λ‹ˆλ‹€.",
      filterResults: "κ°’ 필터링",
      totals: "합계",
      only: "단독",
      vs: "vs",
      by: "by",
    },
  },
}

const locale = 'en' // or 'ko'

Example

Edit this page
Last Updated:: 5/1/25, 1:57 AM
Contributors: Seungwoo321
Next
Slot