agentsclimarketplace

Syncfusion vue data manager

Skill syncfusion/vue-ui-components-skills/skills/syncfusion-vue-data-manager

This repository contains agent prompts for creating skills and organizing AI agent capabilities.

Install
npx -y skills add syncfusion/vue-ui-components-skills --skill syncfusion-vue-data-manager

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Implements Syncfusion Vue DataManager for local/remote binding, CRUD, querying, caching, and middleware. Supports JsonAdaptor, ODataAdaptor, ODataV4Adaptor, UrlAdaptor, WebApiAdaptor, WebMethodAdaptor, RemoteSaveAdaptor, GraphQLAdaptor, CustomDataAdaptor, and CustomAdaptor. Covers Query class, filtering, sorting, paging, grouping, persistence, offline mode, caching, and error handling.

SKILL.md

11.2 KB, as published. Nobody here has run it

Syncfusion Vue DataManager: Comprehensive Guide

When to Use This Skill

Reference this skill when you need to:

  • Set up DataManager in Vue 2, Vue 3, or Quasar
  • Bind data (local arrays or remote APIs)
  • Query and filter data with the Query class
  • CRUD operations (insert, update, delete)
  • Choose an adaptor (10 types available)
  • Add authentication via middleware/headers
  • Optimize performance with caching
  • Work offline with data persistence
  • Pattern guidance for Composition API vs Options API

⚠️ Security & Trust Boundary

  • This skill generates code only, the agent does not execute data operations or fetch remote endpoints β€” all DataManager interactions occur solely within the user's application at runtime.
  • Generated code must treat all third-party API responses as untrusted input, never bind to unvalidated or user-provided URLs, and ensure authentication is enforced on all remote endpoints.

Key Concepts Overview

ConceptWhen to UseReference
SetupInstalling & initial configsetup-vue-2.md, setup-vue-3.md, setup-quasar.md
Data BindingConnecting data sourcesdata-binding.md
QueryingFiltering, sorting, paginationquerying.md
CRUDInsert, update, delete recordscrud-operations.md
AdaptorsChoosing data source typeadaptors-guide.md
CachingPerformance optimizationcaching.md
MiddlewareAuthentication, transformationmiddleware.md
HeadersCustom HTTP headershow-to-headers.md
ParametersSend extra query paramshow-to-parameters.md
OfflineWork without internethow-to-offline.md

πŸ“Š Framework & API Coverage

FeatureVue 2Vue 3QuasarCompositionOptions
Setupβœ…βœ…βœ…-βœ…
Composition API-βœ…βœ…βœ…-
Local Dataβœ…βœ…βœ…βœ…βœ…
Remote Dataβœ…βœ…βœ…βœ…βœ…
10 Adaptorsβœ…βœ…βœ…βœ…βœ…
CRUDβœ…βœ…βœ…βœ…βœ…
Queryingβœ…βœ…βœ…βœ…βœ…
Cachingβœ…βœ…βœ…βœ…βœ…
Middlewareβœ…βœ…βœ…βœ…βœ…

πŸš€ Quick Start

Vue 3 Composition API (Recommended)

import { onMounted, ref } from 'vue';
import { DataManager, Query, ODataV4Adaptor } from '@syncfusion/ej2-data';

export default {
  setup() {
    const items = ref([]);

    onMounted(async () => {
      const dm = new DataManager({
        url: 'url',
        adaptor: new ODataV4Adaptor()
      });

      try {
        const result = await dm.executeQuery(new Query().take(10));
        items.value = result.result;
      } catch (error) {
        console.error('Error:', error);
      }
    });

    return { items };
  }
}

Vue 2 Options API

import { DataManager, Query, ODataV4Adaptor } from '@syncfusion/ej2-data';

export default {
  data() {
    return { items: [] };
  },
  mounted() {
    const dm = new DataManager({
      url: 'url',
      adaptor: new ODataV4Adaptor()
    });

    dm.executeQuery(new Query().take(10))
      .then((result) => {
        this.items = result.result;
      })
      .catch((error) => {
        console.error('Error:', error);
      });
  }
}

πŸ“– Documentation Navigation

Getting Started (Choose Your Framework)

New to DataManager? Start here:

πŸ“„ setup-vue-2.md β€” Vue 2 with Options API

  • Vue CLI installation
  • Vue 2 lifecycle patterns
  • First DataManager example

πŸ“„ setup-vue-3.md β€” Vue 3 with Composition & Options API

  • Vite project setup
  • reactive() vs ref()
  • onMounted lifecycle
  • Performance tips

πŸ“„ setup-quasar.md β€” Quasar Framework

  • Quasar CLI bootstrap
  • Boot file configuration
  • Q-Grid integration
  • Build optimization

Core Features

Understanding Data Binding:

πŸ“„ data-binding.md

  • Local data binding (json property)
  • Remote data binding (url + adaptor)
  • Error handling by HTTP status
  • Promise patterns

Manipulating Data (CRUD):

πŸ“„ crud-operations.md

  • insert() β€” Add new records
  • update() β€” Modify existing records
  • remove() β€” Delete records
  • Batch operations with saveChanges()
  • keyField in update/remove methods

Querying & Filtering:

πŸ“„ querying.md

  • from() β€” Specify resource
  • select() β€” Choose fields
  • where() β€” Filter conditions
  • orderBy() β€” Sorting
  • take/skip β€” Pagination
  • search() β€” Full-text search
  • group() β€” Data grouping

Data Adaptors (10 Types)

Selecting the Right Adaptor:

πŸ“„ adaptors-guide.md

  • JsonAdaptor β€” Local in-memory arrays
  • ODataAdaptor β€” OData v3 services
  • ODataV4Adaptor β€” OData v4 endpoints
  • UrlAdaptor β€” Generic REST APIs
  • WebApiAdaptor β€” ASP.NET Web API (Items, Count format)
  • WebMethodAdaptor β€” ASP.NET web methods
  • RemoteSaveAdaptor β€” Client queries + server CRUD
  • GraphQLAdaptor β€” GraphQL endpoints
  • CustomDataAdaptor β€” Custom request/response
  • CustomAdaptor β€” Extend built-in adaptors

Includes decision tree and comparison matrix.


Advanced Features

Performance Optimization:

πŸ“„ caching.md

  • enableCache property
  • How caching works
  • Auto-clearing rules
  • When to enable/disable

Request Customization:

πŸ“„ middleware.md

  • applyPreRequestMiddlewares() β€” Modify requests
  • applyPostRequestMiddlewares() β€” Transform responses
  • Adding custom headers
  • Authentication token injection

How-To Guides

Quick Solutions for Common Tasks:

πŸ“„ how-to-headers.md

  • Adding static headers
  • Dynamic headers per request
  • JWT/Bearer authentication
  • Content negotiation

πŸ“„ how-to-parameters.md

  • Sending additional query parameters
  • Custom API formats
  • Different adaptor parameter styles

πŸ“„ how-to-offline.md

  • Enabling offline mode
  • localStorage persistence
  • Sync strategies
  • Conflict resolution

πŸ”’ Security Warning: localStorage and sessionStorage store data unencrypted in the browser. Never store sensitive data (passwords, tokens, PII, payment info, user secrets, authentication credentials) in persisted TreeGrid state. State persistence is safe for UI state only (expand/collapse state, page number, sort order, column visibility, filter selections). For sensitive configuration or user data, use secure server-side session storage instead.


🎯 Common Patterns

Local Data Binding

// Vue 3 Composition API
import { ref } from 'vue';
import { DataManager, Query, JsonAdaptor } from '@syncfusion/ej2-data';

const items = ref([]);

const data = [
  { OrderID: 10248, CustomerID: 'VINET', Freight: 32.38 },
  { OrderID: 10249, CustomerID: 'TOMSP', Freight: 11.61 }
];

const dm = new DataManager({ json: data, adaptor: new JsonAdaptor() });
items.value = dm.executeLocal(new Query().take(10));

Remote Data with Error Handling

const dataManager = new DataManager({
  url: 'url',
  adaptor: new WebApiAdaptor()
});

dataManager.executeQuery(new Query().take(10))
  .then((result) => {
    console.log('Success:', result.result);
  })
  .catch((error) => {
    const statusCode = error.status;
    if (statusCode === 401) {
      console.error('Unauthorized - please login');
    } else if (statusCode === 404) {
      console.error('Data not found');
    } else if (statusCode === 0) {
      console.error('Network error');
    }
  });

Filtering with Vue 3 Composition API

import { ref, computed } from 'vue';
import { Query } from '@syncfusion/ej2-data';

const dm = new DataManager({ json: allData });
const searchText = ref('');

const filteredData = computed(() => {
  if (!searchText.value) return allData;
  
  return dm.executeLocal(
    new Query().where('CustomerID', 'contains', searchText.value)
  );
});

Authentication Middleware

πŸ”’ Security Warning: localStorage and sessionStorage store data unencrypted in the browser. Never store sensitive data (passwords, tokens, PII, payment info, user secrets, authentication credentials) in persisted TreeGrid state. State persistence is safe for UI state only (expand/collapse state, page number, sort order, column visibility, filter selections). For sensitive configuration or user data, use secure server-side session storage instead.

const dataManager = new DataManager({
  url: 'url',
  adaptor: new WebApiAdaptor()
});

// Apply middleware to add auth token
dataManager.applyPreRequestMiddlewares([
  async (context) => {
    const token = localStorage.getItem('auth_token');
    context.request.headers['Authorization'] = `send_token`;
  }
]);

πŸ”§ DataManager Configuration

const dataManager = new DataManager({
  // Data source
  url: 'url',        // Remote endpoint
  json: localArray,                            // Local array
  
  // Adaptor selection
  adaptor: new WebApiAdaptor(),              // Adaptor type
  
  // Headers & auth
  headers: [...],
  
  // Network settings
  crossDomain: true,                          // Enable CORS
  offline: false,                             // Offline mode
  enableCache: true,                          // Caching
  
  // Persistence
  enablePersistence: true,                    // Enable state persistence
  id: 'dataManager_vue',                      // Persistence ID
  ignoreOnPersist: ['temp', 'debug'],        // Properties to exclude
  timeZoneHandling: true                      // Timezone offset handling
});

❌ Common Errors & Solutions

ErrorCauseSolution
401 UnauthorizedMissing/expired auth tokenAdd middleware with fresh token
404 Not FoundWrong endpoint URLVerify API endpoint URL
0 (Network Error)No internet connectionEnable offline mode
Cross-Origin ErrorCORS not enabledSet crossDomain: true

βœ… Best Practices

  1. Always set adaptor β€” Choose correct adaptor for your backend
  2. Pass keyField in CRUD methods β€” Required as first parameter in update/delete
  3. Use async/await β€” More readable than .then()/.catch()
  4. Add error handling β€” Catch HTTP errors
  5. Enable caching β€” Reduce server requests
  6. Use middleware β€” Add auth globally
  7. Test both APIs β€” Composition & Options patterns
  8. Handle network errors β€” Status code 0 means no internet
  9. Use typed interfaces β€” TypeScript support

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.