Skip to content

Instantly share code, notes, and snippets.

View andresilveirah's full-sized avatar
💭
🤖

André Herculano andresilveirah

💭
🤖
View GitHub Profile

Unified Wrapper

The majority of (if not all) our clients, when integrating with our SDKs, have pointed out the integration is really cumbersome when covering both GDPR and CCPA. We also pay a high price in terms of development to maintain two repositories in sync (x2 platforms, iOS and Android).

In oder to solve this problem we're merging the two SDKs into one meaning the SDKs will no longer "know" if they are dealing with CCPA or GDPR only. Instead, they will deal with all legislations at the same time.

POST message-url?inApp=true&native=true|false

Also known as "get", this endpoint will receive the account/property/campaign info as well as meta and uuid for all legislations (gdpr/ccpa).

Request

@mortocks
mortocks / useBackButtonEffect.js
Last active November 26, 2022 14:32
Override the back button action in React Navigations stack header. Useful if you want to pass parameters back to the previous screen #react-native #react-navigation
import { useLayoutEffect } from 'react';
import { HeaderBackButton } from '@react-navigation/stack';
/**
* Override the back button action in React Navigations stack header
* @param { Effect } The action to be triggered
*/
const useBackButtonEffect = effect => {
useLayoutEffect(() => {
@bigearsenal
bigearsenal / URLProtocol + URLSession.swift
Last active February 14, 2024 14:09
Custom URLProtocol with URLSession
//
// MyURLProtocol.swift
// NSURLProtocolExample
//
// Created by Chung Tran on 26/08/2017.
// Copyright © 2017 Zedenem. All rights reserved.
//
import UIKit
var requestCount = 0
@everm1nd
everm1nd / rubocop.sh
Last active January 8, 2020 04:31
Run Rubocop locally for changed files only
git status --porcelain | grep -v "D " | cut -c4- | grep "\.rb\|rake" | xargs rubocop -a
@jodosha
jodosha / associations_test.rb
Created October 16, 2015 14:46
Test for Lotus::Model associations
require 'bundler/setup'
require 'lotus/model'
require 'lotus/model/migrator'
require 'pg'
class Bicycle
include Lotus::Entity
attributes :parts
end
@kristopherjohnson
kristopherjohnson / firstDifferenceBetweenStrings.swift
Last active December 8, 2022 18:31
Swift code to find differences between strings and display them in a readable way, useful for displaying unit test results
import Foundation
/// Find first differing character between two strings
///
/// :param: s1 First String
/// :param: s2 Second String
///
/// :returns: .DifferenceAtIndex(i) or .NoDifference
public func firstDifferenceBetweenStrings(s1: NSString, s2: NSString) -> FirstDifferenceResult {
@staltz
staltz / introrx.md
Last active May 17, 2024 07:59
The introduction to Reactive Programming you've been missing
@jed
jed / LICENSE.txt
Created May 20, 2011 13:27 — forked from 140bytes/LICENSE.txt
generate random UUIDs
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Jed Schmidt <http://jed.is>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE