All Products
Search
Document Center

DataV:Custom development component blueprint description

Last Updated:Jun 18, 2026

Prerequisites

The desktop version of the development tool is required. For more information, see the desktop version of the development tool instructions.

Background information

To enable custom components to work with the DataV blueprint editor, you must follow the editor's development rules. After you create a component with the developer tool, an index.js file and a package.json file are generated in the local component package folder. You need to modify these files to implement blueprint editor integration.

Event trigger

The following example uses the Current Value Change event of the ticker board component to demonstrate event trigger implementation. image.png

  1. Open the package.json file after creating the component with the developer tool.

  2. Locate the events field within the datav field in the package.json file.

    Important

    Ensure each event in the blueprint editor matches the event specified in the custom component's events field; otherwise, the editor will not detect it.

  3. Define events in the current events field, customizing the description for the event-name and the value field name. 事件触发文件内容修改

    Note

    You can customize both event and field names with multiple entries, enhancing the variety of events displayed on the blueprint editor node page.

  4. Open the index.js file and configure the event name for the emit method.

    this.emit('event-name', obj); 
    Note

    The event name used in emit must match the one in the package.json file. Pass parameters as an object type, and include multiple fields if necessary.

Import data interface

The following example uses the ticker board component's Import Data Interface action to demonstrate how to implement the Import Data Interface action in custom components. image.png

  1. Open the index.js file after creating the component with the developer tool.

  2. Find the render field within the datav field in the index.js file.

  3. Customize the action code logic for the Import Data Interface within the render field. 导入数据接口代码逻辑

    Note

    You can customize action logic with multiple entries, which increases the variety of actions available on the blueprint editor node page.

Add interactive actions

The following example uses the Show and Hide actions of the ticker board component to demonstrate how to add interactive actions. image.png

  1. Open the package.json file after creating the component with the developer tool.

  2. Search for the publicHandler field within the datav field in the package.json file.

  3. Customize the descriptions for Show and Hide within the publicHandler field, ensuring they align with the method names in the index.js file.  隐藏显示动作自定义

    Note

    Customize action logic with multiple entries to expand the range of actions displayed on the blueprint editor node page.

  4. Set the content of container in the index.js file. 显示隐藏动作字段名

    Note

    Field names in container must correspond with those in the package.json file.

    this.container.show(); // Show code, developer customizes
    this.container.hide(); // Hide code, developer customizes