Skip to content

Releases: nvxdm/strapi-plugin-remote-select

v5.0.0

Choose a tag to compare

@nvxdm nvxdm released this 06 Mar 18:56

Breaking Changes

  • Version scheme: Major version now matches Strapi major version. Jumped from 2.x to 5.0.0 to align with Strapi 5.
  • Replaced lodash-es with micromustache: Template syntax for option labels changed from lodash templates (<%= field %>) to mustache-style ({{ field }}). Supports dot-path access for nested properties (e.g., {{ address.city }}).
  • Search placeholder changed: The {q} placeholder in URLs/bodies is now {{ q }}, consistent with the mustache template syntax used everywhere else.

Added

  • Presets system: Define reusable fetch configurations in config/plugins.js under remote-select.presets. Presets encapsulate URL, method, headers, body, and mapping — so content editors just pick a preset name instead of configuring each field manually.
    • New GET /remote-select/presets endpoint returns available preset names.
    • Preset selector dropdown in the admin field configuration UI (auto-populated from server config). Falls back to a free-text input if presets can't be loaded.
    • Server-side preset resolution with variable and search substitution.
    • New PresetFetchOptionsSchema yup validation for preset-based requests.
  • RemoteSelectPluginOptions type export from the server entry point, allowing typed plugin configuration in consumer projects.
  • fetchPresetNames utility: Synchronous XHR call during admin plugin registration to load preset names for the field configuration UI.

Changed

  • Refactored OptionsProxyService: Complete rewrite. Now handles both custom and preset configs, with clearer separation of concerns (variable substitution, header parsing, option label/value extraction, deduplication).
  • Refactored admin components (RemoteSelect.tsx, SearchableRemoteSelect.tsx): Both now build request bodies conditionally based on whether a preset or custom config is used. Searchable select delegates {{ q }} substitution to the server for presets.
  • Replaced lodash-es debounce in SearchableRemoteSelect with a simple setTimeout/clearTimeout pattern, removing the lodash-es dependency entirely.
  • Improved validation schema: RemoteSelectFetchOptions.schema.ts now validates method field and includes search parameter. Added separate PresetFetchOptionsSchema for preset-based requests.
  • Updated getRemoteSelectRegisterOptions: Now accepts presetNames parameter to dynamically build the preset selector. Added "Configuration preset" section to the field settings UI.
  • Cleaned up dependencies: Removed lodash-es and @types/lodash-es. Added micromustache as a runtime dependency.
  • Server config default now includes presets: {} alongside variables: {}.
  • Updated README.md: Documentation reflects new template syntax, preset system, and updated configuration examples.

Removed

  • lodash-es dependency: Replaced entirely by micromustache for templates and native setTimeout for debounce.
  • server/src/services/service.ts: Removed unused legacy service file.

2.0.4

Choose a tag to compare

@nvxdm nvxdm released this 18 Jul 21:42
Update custom field types and bump version to 2.0.4

Change custom field types from 'string' to 'text' for better compatibility. Increment package version to 2.0.4 to reflect these updates.

1.0.8

Choose a tag to compare

@nvxdm nvxdm released this 09 Jun 21:59

Add support for dynamic variables in API requests

Introduced the ability to use configurable variables in API URLs, headers, and bodies for the remote-select plugin. Updated relevant service methods, configuration, and documentation to support this feature. Minor type and field adjustments were also applied for better consistency.

2.0.1

Choose a tag to compare

@nvxdm nvxdm released this 10 Dec 11:09

Strapi 5 support is released

1.0.4

Choose a tag to compare

@nvxdm nvxdm released this 11 Jun 14:44
Add requirements section to README

1.0.3

Choose a tag to compare

@nvxdm nvxdm released this 11 Jun 11:39
npm publish fixes