Skip to content

Go values as objects and properties #704

Open
@FlorianUekermann

Description

@FlorianUekermann

There is no straightforward way of storing go values in a js object or property. I know this restriction is intentional, but it is a very inconvenient one at times. All workarounds I know of have severe problems (serialization overhead, global map[string]interface{} won't be garbage collected).

I suspect that there are proper workarounds for this problem using js.InternalObject, but it is unclear to me how to recover the go value from the resulting *js.Object and if I can use it with js.Object.Set/Get.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions