Skip to content

Make possible to reactify-component to return a functional component #548

@m-lce

Description

@m-lce

I did not found any way to make reactify-component return a functional component.
Even if I use it with a functional compiler like this :

(def functional-compiler (reagent.core/create-compiler {:function-components true}))
(defn reagent-cmp
[props] 
[:> rn/Text "Hello]" )
(def react-cmp (reactify-component reagent-cmp functional-compiler))

react-cmp will no be a functional component. We can use as-element in the reagent-cmp and use the function as a react component but this prevent us to use ratom inside.

Will it be possible to add an option to make reactify-component return a functional component ?

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions