import React from 'react' ; import { defineComponent } from 'reactivue' ; import { useQuery } from 'villus' ; const Posts = `
{
  company {
    founded
    name
  }
}
` ; export const Query = defineComponent ( ( ) => { const { data } = useQuery ( { query : Posts , } ) ; return { data } ; } , ( { data } ) => { return ( < div className = "card" > < p > useQuery < /p> < pre className = "p-1" > { ! data ? 'Loading' : JSON . stringify ( data , null , 2 ) } < /pre> < /div>); } ) ;