All skills
wix avatar

/wix-app

@dc6f1fa official
by Wix.comwix/skills33 stars
33

Build and review Wix CLI app extensions — dashboard pages, modals, plugins, menu plugins, custom element widgets, Editor React components, site plugins, embedded scripts, backend APIs, backend events, service plugins, data collections, and App Market readiness. Use when building ANY feature or extension for a Wix CLI app or preparing a Wix app for App Market review. Triggers on: add, build, create, implement, help me, dashboard, widget, plugin, backend, API, event, collection, embedded script, service plugin, Editor React component, checkout, shipping, tax, discount, SPI, CMS, schema, tracking, popup, admin panel, menu item, modal, validate, test, verify, register extension, App Market, app review, submission readiness.

Use this Skill: https://skilld.dev/gh/wix/skills/wix-app

This session only. Nothing lands on disk.

referenceseditor-react-componentFUNCTION-HANDLERS.md

≈998 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Function Handlers

When creating a component or changing interactions, expose common optional callbacks by capability, without requiring an explicit request.

Default Support

Apply defaults to the public interaction surface:

Component capability Default optional props
Pointer/click interaction, including native controls onClick, onMouseIn, onMouseOut
Focusable control onFocus, onBlur
Editable value, text, or selection onChange

Combine matching rows; leave decorative elements alone. Explicit API restrictions override defaults. Specialized callbacks (onDblClick, onPlay, onEnded, onActivate, etc.) require a request.

Classify composite controls by their interactive descendants. For example, a radio-based rating input matches all three rows and exposes all six callbacks.

Standard SDK Handlers

Use the exact SDK prop name and wire it to the matching React DOM event.

SDK prop React DOM prop Type Zero config domEvent
onClick onClick (event: React.MouseEvent) => void POINTER
onDblClick onDoubleClick (event: React.MouseEvent) => void POINTER
onChange onChange (event: React.ChangeEvent<HTMLElement>) => void CHANGE
onFocus onFocus (event: React.FocusEvent) => void FOCUS
onBlur onBlur (event: React.FocusEvent) => void FOCUS
onMouseIn onMouseEnter (event: React.MouseEvent) => void POINTER
onMouseOut onMouseLeave (event: React.MouseEvent) => void POINTER

React onChange fires on live text edits and selection changes. Pass that ChangeEvent directly. Do not synthesize a commit callback from blur or cast a FocusEvent to ChangeEvent.

Callbacks only notify; they never enable controlled mode. Internal handlers run component logic, then call the optional callback once, preserving event payloads and disabled/read-only guards. Behavior must work without callbacks or consumer prop updates. Forward directly when no internal logic is needed. Add controlled state only when requested; preserve existing controlled APIs when editing.

import * as React from 'react';

export type ActionProps = {
  onClick?: (event: React.MouseEvent) => void;
  onMouseIn?: (event: React.MouseEvent) => void;
  onMouseOut?: (event: React.MouseEvent) => void;
  onFocus?: (event: React.FocusEvent) => void;
  onBlur?: (event: React.FocusEvent) => void;
};

export const Action: React.FC<ActionProps> = (props) => {
  const { onClick, onMouseIn, onMouseOut, onFocus, onBlur } = props;
  const [count, setCount] = React.useState(0);

  const handleClick = (event: React.MouseEvent) => {
    setCount((value) => value + 1);
    onClick?.(event);
  };

  return (
    <button
      type="button"
      onClick={handleClick}
      onMouseEnter={onMouseIn}
      onMouseLeave={onMouseOut}
      onFocus={onFocus}
      onBlur={onBlur}
    >
      Clicked {count} times
    </button>
  );
};

Zero config requires SDK names, not onDoubleClick, onMouseEnter, or onMouseLeave, in public props.

Custom Callbacks

Custom notifications use () => void; zero config emits no event parameter for unrecognized callback names. Custom callbacks must not declare React event parameters. Use a standard SDK handler above when the event is public:

export type VideoPlayerProps = {
  onPlay?: () => void;
  onPause?: () => void;
  onEnded?: () => void;
};

export const VideoPlayer: React.FC<VideoPlayerProps> = (props) => {
  const { onPlay, onPause, onEnded } = props;
  return (
    <video
      controls
      onPlay={() => onPlay?.()}
      onPause={() => onPause?.()}
      onEnded={() => onEnded?.()}
    />
  );
};

Checklist

  • Defaults match capabilities; specialized callbacks are requested.
  • SDK names, DOM mappings, and payloads match the contract.
  • Internal behavior works independently and notifies callbacks once.

Source: SKILL.md on GitHub

1 warningtoday4 checks · Risk SAFE
  • Gen Agent Trust Hubtoday

    This skill is a specialized development toolkit for building extensions on the Wix platform. It provides comprehensive instructions for creating dashboard pages, backend APIs, and site plugins using the Wix CLI and SDKs. No malicious patterns were detected; the skill's behaviors, such as dependency management, command execution for builds, and local script execution for code reviews, are entirely consistent with its purpose as a developer productivity tool for the Wix ecosystem.

  • Sockettoday

    1 alert: gptAnomaly

  • Snyktoday

    Risk: LOW · No issues

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at dc6f1fa. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated 2 days ago
compatibility
requires `@wix/cli` >= 1.1.192.

README badge

README badge for wix/skills/wix-app

Builds dashboard pages, modals, plugins, custom widgets, Editor React components, backend APIs, events, service plugins, and data collections for Wix CLI apps. Provides decision logic, API patterns, and validation workflows; scaffolding is owned by the Wix CLI via `wix generate --params`.

Generated from the current SKILL.md.

What extension types does this skill cover?
All Wix CLI app extension types: dashboard pages, modals, plugins, menu plugins, custom element widgets, Editor React components, site plugins, embedded scripts, backend APIs, backend events, service plugins, and data collections.
Does this skill scaffold the extension files for me?
The Wix CLI owns scaffolding via `wix generate --params` for all extension types except Backend API. This skill provides decision logic, API guidance, and business-logic patterns to fill in the generated stubs. Backend API files must be created manually.
What Wix CLI version is required?
The skill requires @wix/cli >= 1.1.192.
Do I need to create a Data Collection extension for app-specific data?
Yes, if you're saving or persisting app-specific data, managing domain entities in a dashboard, or running a service plugin that reads app-configured data. The skill infers this automatically—you don't need to explicitly request it.
Does this skill cover Wix Stores API usage?
Yes. When using any Wix Stores API (products, inventory, orders), the skill requires dual V1/V3 catalog support and references the Stores Versioning guide for module selection and field mapping.

Generated from the current SKILL.md. These answers refresh after source changes.