'MVVM, MVC pattern in React

I know that Facebook described React as V(view), but I saw many frontend developers uses MV* pattern in their React app (when I googled MV* articles)

So I'm confused is it possible to use MV* pattern in V (react) or they just call it "MV* pattern" cause don't know what to say their architecture?

For example, according to the articles that say using MV* in React I've seen was like below code.

// View
const MainUiComponent = ({serverData}) => {
  const {data, eventHandler} = useViewModel(serverData)

  return (<button onClick={eventHandler}>{data}</button>) 
} 


// business logic related on View
function useViewModel() {
  const [data, setData] = useState()

  const serverData = () => {
    // fetch logic
  } 

  const eventHandler = () => {
    // something
  }

  return {data, eventHandler};
}

So my question is, can I call useViewModel as ViewModel? Or is it just Hook that seperate business logic from view, not ViewModel?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source