This tutorial will help you integrate Flexmonster with Vue 3. Watch the tutorial in the video format: Vue pivot table guide.
Flexmonster has a 30-day free trial, with no registration required to start the evaluation. You can also test the component using our sample Vue 3 project or the Vue pivot table demo.
To integrate with Vue 2, see Integration with Vue 2.
npm install -g flexmonster-cli
Skip this step if you already have a Vue 3 app.
Step 1.1. Start creating a Vue 3 app with create-vue. You can create an ES6-based or TypeScript-based project:
npm create vue@latest
You will be prompted to choose optional features for the project. For simplicity, choose No for all the features.
npm create vue@latest
You will be prompted to choose additional features for the project. Choose Yes for TypeScript to create a TypeScript project. For simplicity, choose No for other features.
Step 1.2. Install npm dependencies needed for the project:
cd <your-project-name> && npm install
Learn more about creating a new project in the Vue documentation.
To get Flexmonster for Vue, run the following command inside your project:
flexmonster add vue-flexmonster
This command downloads the vue-flexmonster wrapper to node_modules/ and adds it as a dependency to package.json.
Step 3.1. If your project is TypeScript-based, declare the vue-flexmonster/vue3 module in the env.d.ts file:
/// <reference types="vite/client" />
declare module "vue-flexmonster/vue3"
Note If your project was generated by Vue CLI, the declare module "vue-flexmonster/vue3" line should be added to the src/shims-vue.d.ts file.
Step 3.2. Import vue-flexmonster/vue3 in the component where you need the pivot table (e.g., in src/App.vue):
<script setup>
// Import the Pivot component and CSS styles
import Pivot from "vue-flexmonster/vue3";
import "flexmonster/flexmonster.css";
</script>
<script setup lang="ts">
// Import the Pivot component and CSS styles
import Pivot from "vue-flexmonster/vue3";
import "flexmonster/flexmonster.css";
</script>
Note In the code snippet above, Flexmonster is added to the Composition API component. To embed Flexmonster when using Options API, see this example: Creating the pivot table using Options API.
Step 3.3. Use the <Pivot> tag to add a Flexmonster instance to the chosen component (e.g., src/App.vue):
<template>
<Pivot
toolbar
/>
</template>
The toolbar is one of the <Pivot> props. Learn more about the <Pivot> component.
Run your application from the console:
npm run dev
Open your project in the browser to see the result.
You can also watch our video tutorial that covers the integration process:
We prepared the following examples of Flexmonster usage:
If you run into any issues during the integration, visit our troubleshooting page.
Can't find your answer here?
Visit the FAQ page
Flexmonster Pivot Table & Charts is a JavaScript pivot table component for adding interactive reporting and data analysis to web applications. Users can summarize, filter, sort, and explore data in pivot tables and charts, drill into results, and export reports.
Flexmonster works in plain JavaScript and TypeScript projects. It also integrates with React, Next.js, Angular, Vue, Blazor, and other technologies. See all integration options.
Flexmonster supports JSON and CSV files, SQL databases, MongoDB, Elasticsearch, and Microsoft Analysis Services (SSAS). You can also connect other data sources through your own backend. See supported data sources.
Flexmonster offers licenses for internal corporate use, SaaS products, and OEM distribution. Pricing varies by license and plan. SaaS projects can also use the free SaaS Entry license during development. Learn more on the pricing page.
Yes. Flexmonster offers a 30-day free trial that lets you evaluate all its features. No credit card is required. The trial version has a watermark.
To get started with Flexmonster, follow our integration guide.