Skip to content

Working with gestures #37

Description

@thitemple

Hey there, I'm trying to work with some animation stuff and I'm having some difficulties. You may have seen my PR alread but I do have another issue that I'd like to understand how to fix it.

The interface IViewProperties inherits from IGestureResponderHandlers

inherit IGestureResponderHandlers

And I was wondering how I could pass it to the view.
I began creating an object:

let panResponderConfig = createEmpty<Fable.Import.ReactNative.PanResponderCallbacks>
let panResponder = RN.PanResponder.create(panResponderConfig)

But then, how am I suppose to pass panResponder.panHandlers to the view?

Usually with javascript this is done this way:

this._panResponder = PanResponder.create({ .... })
<View {...this._panResponder.panHandlers}>....</View>

How can I replicate JavaScript's spread operator and how can I pass that to IViewProperties?

Thanks

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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