Skip to content

Instantly share code, notes, and snippets.

@codetricity
Created August 28, 2017 18:31
Show Gist options
  • Save codetricity/7987b35732e38daea4bbb1da9226e5e8 to your computer and use it in GitHub Desktop.
Save codetricity/7987b35732e38daea4bbb1da9226e5e8 to your computer and use it in GitHub Desktop.
MapD Crossfilter example in the MapD Tweetmap-2 demo
import * as CrossFilter from "@mapd/crossfilter"
import {TABLE_NAME} from "../constants"
let crossfilter = null
export function createCf (con) {
return CrossFilter.crossfilter(con, TABLE_NAME).then(cf => {
crossfilter = cf
return Promise.resolve(cf, con)
})
}
export function getCf () {
return crossfilter
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment