Skip to content

Be able to update the widget with json data without using widget-server #176

@Angelk90

Description

@Angelk90

Feature Description

In addition to how it is currently implemented, it would be useful to:

The http endpoint should return only json data, such as balance, percentage change, chart points, and timestamps.
All rendering and interface composition logic should remain within the widget.

Widget → HTTP Request → JSON Data → Rendering nel Widget

Problem Statement

The main problem with this approach is that the server must know the widget's internal structure and handle rendering.

If the APIs were exposed by a site developed in php, laravel, or any other backend technology, it wouldn't be possible to generate the widget using voltra on the server without replicating all the rendering logic and necessary dependencies.

It would be preferable for the server to simply return the data in json format, regardless of the technology used.

This way, any backend could provide the requested data, while the widget would handle interpreting and rendering it autonomously.

Edit:
Also it seems that VoltraWidgetUpdateWorker only allows making GET calls.

Proposed Solution

No response

Alternatives Considered

No response

Current Library Version

1.4.1

Implementation

  • I would be willing to submit a pull request for this feature

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions