Skip to content

Instantly share code, notes, and snippets.

@HERRKIN
HERRKIN / privacy-policy.md
Created October 6, 2026 22:30
Privacy Policy - Mapas que hablan Publisher

Privacy Policy — Mapas que hablan Publisher

Last updated: October 6, 2026

"Mapas que hablan Publisher" is a private internal tool operated by José Andradez to publish and schedule video content to Facebook Pages and Instagram accounts that he owns and administers.

Data we access

The app uses Meta Graph API permissions solely to publish, schedule and read performance metrics and comments for Pages and Instagram accounts owned by the operator. It does not access data of other users, and it is not offered to the public.

Data we store

@HERRKIN
HERRKIN / privacy-policy.md
Created October 6, 2026 22:29
Privacy Policy - Mapas que hablan Publisher

Privacy Policy — Mapas que hablan Publisher

Last updated: October 6, 2026

"Mapas que hablan Publisher" is a private internal tool operated by José Andradez to publish and schedule video content to Facebook Pages and Instagram accounts that he owns and administers.

Data we access

The app uses Meta Graph API permissions solely to publish, schedule and read performance metrics and comments for Pages and Instagram accounts owned by the operator. It does not access data of other users, and it is not offered to the public.

Data we store

@HERRKIN
HERRKIN / Luminux.js
Created April 4, 2018 16:08
Test code file for Luminux, should be run with babel-node
const binarySearch = (items, x) => {
let low = 0
let high = items.length - 1
while (low <= high) {
const mid = parseInt((low + high) / 2, 10)
const current = items[mid]
if (current > x) {
high = mid - 1
} else if (current < x) {
low = mid + 1
@HERRKIN
HERRKIN / drawer.action.js
Last active March 29, 2018 17:04
linkTo action for drawer links
export default function* linkTo({ payload }) {
const { route, params } = payload
const action = ['Products', 'Configuration', 'Profile'].includes(route)
? NavigationActions.reset({
index: 0,
key: route,
actions: [NavigationActions.navigate({ routeName: route, params })],
})
: NavigationActions.navigate({ routeName: route, params })
yield put(action)
@HERRKIN
HERRKIN / RouteConnect.js
Created March 29, 2018 16:55
HOC that avoids rendering or update unless necesary when using react-navigation
import React, { Component } from 'react'
import { connect } from 'react-redux'
import _ from 'lodash'
export const renderer = (route, Wrapped) =>
class extends Component {
shouldComponentUpdate(props) {
if (!props.render || this.props.currentRoute === 'DrawerOpen') { return false }
const thisProps = JSON.stringify(_.omit(this.props, ['nav', 'navigation', 'screenProps']))
const nextProps = JSON.stringify(_.omit(props, ['nav', 'navigation', 'screenProps']))
@HERRKIN
HERRKIN / apollo.js
Created February 3, 2017 16:03
apollo configuration file
import ApolloClient, {createNetworkInterface} from 'apollo-client'
import {addTypenameToSelectionSet} from 'apollo-client/queries/queryTransform'
import baseURL from './url' // we could use a string url here for example localhost:port/
const getLoginToken = function () {
return window.localStorage['Meteor.loginToken']
}
export const createMeteorNetworkInterface = () => {
let uri = baseURL + '/graphql'
@HERRKIN
HERRKIN / index.js
Created January 17, 2017 22:52
Mutations index.js adding toggleCompleted
import {Resolvers as Auth} from 'meteor/nicolaslopezj:apollo-accounts'
import addTodo from './addTodo'
import toggleCompleted from './toggleCompleted'
export default {
...Auth(),
addTodo,
toggleCompleted
}
@HERRKIN
HERRKIN / toggleCompleted.js
Created January 17, 2017 22:40
toggleCompleted Mutation
import {Todos} from '../../../../lib/Collections'
export default function (root, options, context) {
console.log(options)
if (!context.userId) {
throw new Error('Unknown User (not logged in)')
}
// validate the todo belongs to the user
const todo = Todos.findOne({$and: [{_id: options.todoId}, {owner: context.userId}]})
// if not found throw Error
if (!todo) {
@HERRKIN
HERRKIN / index.js
Created January 17, 2017 21:49
updated Mutation index.js
import {SchemaMutations as Auth} from 'meteor/nicolaslopezj:apollo-accounts'
import addTodo from './addTodo.graphql'
import toggleCompleted from './toggleCompleted.graphql'
export default `
type Mutation {
${Auth()}
${addTodo}
${toggleCompleted}
}
`
@HERRKIN
HERRKIN / index.js
Created January 10, 2017 23:07
Resolvers index.js
import Query from './Query'
import Mutation from './Mutations'
import User from './User'
export default {
...User,
Query,
Mutation
}