Skip to content

pacx webresources js setTemplate

github-actions[bot] edited this page Jul 22, 2025 · 2 revisions

Allows to override the default template used when creating custom JS WebResources.

Aliases

pacx wr js setTemplate
pacx wr setTemplate js

Usage

This command can be used to override the default templates used to create JS WebResources via pacx webresources js create.

PACX supports 4 different types of templates:

  • Form: Used to create JS WebResources meant to be used in forms. (pacx webresources js setTemplate --type Form --file ...)
  • Ribbon (global): Used to create JS WebResources meant to be used in global command bars. (pacx webresources js setTemplate --type Ribbon --file ...)
  • Ribbon (table): Used to create JS WebResources meant to be used in specific table-related command bars. ( (pacx webresources js setTemplate --type Ribbon --forTable --file ...)
  • Other: Generic template for other types of JS WebResources. (pacx webresources js setTemplate --type Other --file ...)

Custom templates may contain 2 dynamic placeholders, that will be replaced with pacx wr create js command options:

  • %NAMESPACE%: will be replaced with the value of --namespace option;
  • %TABLE%: will be replaced with the value of --table option;

Arguments

Long Name Short Name Required? Description Default value Valid values
file f Y The name of the file that contains the new template - String
type t N The type of the template to override. Form Form, Ribbon, Other
forTable ft N To be used in conjunction with --type Ribbon, indicates if the template is for a table command bar. If not specified, is assumed as a global command bar. False true, false

Command list

Clone this wiki locally