Skip to content

Instantly share code, notes, and snippets.

@afreeland
Last active May 1, 2018 20:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save afreeland/0c26acb07558fd730f455f1df4de8300 to your computer and use it in GitHub Desktop.
Save afreeland/0c26acb07558fd730f455f1df4de8300 to your computer and use it in GitHub Desktop.
import React, { Component } from 'react';
import { render } from 'react-dom';
const gql = require('graphql-tag');
import { graphql } from 'react-apollo';
import appRoot from 'app-root-path';
import store from '../../store.js';
const Recent_Query = gql(`
query recent_query($username: String! $type: String! ){
recent (username: $username type: $type){
uid
}
}
`);
class AnalyticHistory extends Component {
constructor(props){
super(props)
}
render(){
return <div>...</div>
}
}
const History_HOC = graphql(Recent_Query, {
options: ({username, type}) => ({ variables: {username, type}})
})(AnalyticHistory)
export default History_HOC;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment