Flexmonster Software License Agreement (“Agreement”) has been revised and is effective as of January 8, 2025.
The following modifications were made:
The modified version of Agreement is available here.
Downloading, installing, and/or continuing to use Flexmonster Software after January 8, 2025, constitutes Licensee’s acceptance of the terms and conditions of the modified version of Agreement. If Licensee does not agree to any of these terms and conditions, they must cease using Flexmonster Software and must not download, install, use, access, or continue to access Flexmonster Software. By continuing to use Flexmonster Software or renewing the license or maintenance after the effective date of these modifications to Agreement, Licensee accepts and agrees to be bound by the terms and conditions of the modified Agreement.
Follow this tutorial to integrate Flexmonster with the Svelte framework.
Flexmonster has a 30-day free trial, with no registration required to start the evaluation. You can also test the component using our sample Svelte project.
Skip this step if you already have a Svelte project.
Сreate a Svelte project by running the following commands in the console:
npx sv create fm-svelte-app
cd fm-svelte-app
You will be prompted to choose configurations for the project. For simplicity, choose the default options for all the features.
To get Flexmonster for Svelte, run the following command inside your project:
npm install svelte-flexmonster --save-exact
Note We recommend installing Flexmonster with the --save-exact flag to avoid unexpected component updates.
Step 3.1. Import Flexmonster in the page where you need the pivot table (e.g., src/routes/+page.svelte
):
<script lang="ts">
import { Flexmonster } from "svelte-flexmonster";
</script>
Step 3.2. If your project has a global stylesheet (e.g., src/styles.css
), import the Flexmonster styles there:
@import "flexmonster/flexmonster.min.css";
Alternatively, you can add Flexmonster styles to the <script>
section of your page (e.g., src/routes/+page.svelte
):
<script lang="ts">
import { Flexmonster } from "svelte-flexmonster";
import "flexmonster/flexmonster.css";
</script>
Step 3.3. Use the <Flexmonster>
tag to add a Flexmonster instance to the chosen component (e.g., src/routes/+page.svelte
):
<script lang="ts">
import { Flexmonster } from "svelte-flexmonster";
</script>
<div>
<Flexmonster
toolbar
/>
</div>
Run your project from the console:
npm run dev
To see the result, open http://localhost:5173/
in your browser.
To shut down the project from the console, press Ctrl + C
(Control + C
on macOS).
The Svelte sample project contains several examples of Flexmonster Pivot usage and customization:
report
, toolbar
, and other initialization parameters in the pivot grid for Svelte.updateData()
method.customizeCell()
API call.You can try all of these examples right from the project’s starting page.