Skip to content

Convert the segmented control into React Hooks#16

Open
alotama wants to merge 5 commits into
lorensr:masterfrom
alotama:master
Open

Convert the segmented control into React Hooks#16
alotama wants to merge 5 commits into
lorensr:masterfrom
alotama:master

Conversation

@alotama

@alotama alotama commented Jun 4, 2019

Copy link
Copy Markdown

No description provided.

@lorensr

lorensr commented Jun 4, 2019

Copy link
Copy Markdown
Owner

Hey, thanks for the contribution. I'll merge if you can get storybook working (npm start):

image

@lorensr

lorensr commented Jun 4, 2019

Copy link
Copy Markdown
Owner

Also, looks like the effect is returning an extra function? And can add [] to have it only run on mount:

  useEffect(() => {
    const defaultOption = find(options, { default: true })
    setValue(defaultOption.value)
  }, [])

@alotama

alotama commented Jun 4, 2019

Copy link
Copy Markdown
Author

I would check it!

@alotama

alotama commented Jun 4, 2019

Copy link
Copy Markdown
Author

I upgraded the version of React in the dependencies. I also convert the FormsySegmentedControl to Hooks

@lorensr

lorensr commented Jun 6, 2019

Copy link
Copy Markdown
Owner

What's the "Mapa"? ☺️

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants