Skip to content

Foreign.Object instead of Foreign? #51

@jamesdbrock

Description

@jamesdbrock

Should this use Foreign.Object instead of Foreign?

foreign import pushState :: Foreign -> DocumentTitle -> URL -> History -> Effect Unit

The purescript-foreign repo is more for when we're reading plain JavaScript objects, and the purescript-foreign-object repo is more for when we're writing plain JavaScript objects. This is more like the latter situation, from the perspective of the purescript-web-html user API.

Like, I want to pass Foreign.Object.empty as the first argument to pusState, but there is no empty in purescript-foreign. So I’m going to pass unsafeToForeign {}.

And similarly for everywhere else in this repo.

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: needs more infoThis issue needs more info before any action can be done.status: wontfixThe maintainers of this library don't think the issue is actually a problem.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions