Constructor
# <SmartMeterItem energyUrl powerUrl />
This component is just a container used to hold any SmartMeter sensor item. It is responsible for making periodic calls to fetch the current value of the sensor to be displayed in the dashboard. It relies on useMultipleFetch and useInterval hooks.
PropTypes:
Name | Type | Required | Description | Default |
---|---|---|---|---|
energyUrl |
string | Yes | The endpoint to fetch the current energy value from. | |
powerUrl |
string | Yes | The endpoint to fetch the current power value from. |