Tuya MiniApp
  • Introduction
  • Development
  • Solution
Panel Development Solution
AI Application Development Solution
Full-scenario Application Solution
DEVELOPER DOCS
  • Introduction
  • Usage Scenarios
  • Solutions
    • General Category Capabilities
      • Core Capabilities
      • Panel Multi-language
      • Smart Device Model
        • Usage
          • constructor
          • init
          • onInitialized
          • offInitialized
          • getDevInfo
          • getDpSchema
          • getDpState
          • getNetwork
          • getBluetooth
          • publishDps
          • queryDps
          • destroy
          • onDpDataChange
          • onDeviceOnlineStatusUpdate
          • onDeviceInfoUpdated
          • onNetworkStatusChange
          • onBluetoothAdapterStateChange
          • offDpDataChange
          • offDeviceOnlineStatusUpdate
          • offDeviceInfoUpdated
          • offNetworkStatusChange
          • offBluetoothAdapterStateChange
        • Interceptors
        • FAQ
      • Smart Group Model
      • Function Point Parsing Set
      • Hooks
      • Utility Methods
    • Vertical Category Capabilities
  • Use Cases

SmartDeviceModel.destroy()

Requires:
@ray-js/panel-sdk≥1.0.0
Usage note

After destruction, the instance can no longer be used; all listeners registered via on* methods are removed.

Description

Destroy the current smart device instance and all event listeners

Parameters

None

Return Value

None

Examples

Example

device.destroy();
Previous pagequeryDpsNext pageonDpDataChange
On this page