Skip to content

AssignTo a map[string]any #21

@marcus-wishes

Description

@marcus-wishes

Hi,
I am trying to get an array of JavaScript objects into go (wasm).
The problem is that I don't know the properties of this object, so I figured I could use a map[string]any.
But in the any part (which can only be string, number, or []string, []number in that case), I get in the frontend it:

Error: invalid assignment from JS type: object to Go kind: interface

I am not sure how to debug actually in wasm, with the systall/js thing. This is my first contact with wasm.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions