Skip to content

Instantly share code, notes, and snippets.

View ThadeusAjayi's full-sized avatar

Ajayi Thadeus ThadeusAjayi

View GitHub Profile
@ThadeusAjayi
ThadeusAjayi / ArrayUtil.java
Created March 27, 2021 20:41 — forked from mfmendiola/ArrayUtil.java
ReadableArray and ReadableMap serialization helpers for the React Native—Android bridge.
/*
ArrayUtil exposes a set of helper methods for working with
ReadableArray (by React Native), Object[], and JSONArray.
MIT License
Copyright (c) 2020 Marc Mendiola
Permission is hereby granted, free of charge, to any person obtaining a copy
package com.mma.fingerprint;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.EnumMap;
import java.util.concurrent.LinkedBlockingQueue;
@ThadeusAjayi
ThadeusAjayi / DateUtilsFormatDateTime.java
Created August 22, 2018 14:45 — forked from MizzleDK/DateUtilsFormatDateTime.java
Examples with DateUtils.formatDateTime()
long date = 1407869895000L; // August 12, 2014, 8:58PM
// August 12, 2014 (default)
DateUtils.formatDateTime(this, date, 0);
// Aug 12, 2014 (default with abbreviated month)
DateUtils.formatDateTime(this, date, DateUtils.FORMAT_ABBREV_MONTH);
// August 12 (date without year)
DateUtils.formatDateTime(this, date, DateUtils.FORMAT_NO_YEAR);
@ThadeusAjayi
ThadeusAjayi / include_list_viewpager.xml
Created July 4, 2018 15:50 — forked from iPaulPro/include_list_viewpager.xml
CollapsingToolbarLayout with TabLayout
<?xml version="1.0" encoding="utf-8"?><!--
~ Copyright (C) 2015 The Android Open Source Project
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
@ThadeusAjayi
ThadeusAjayi / sketch-never-ending.md
Created April 10, 2018 22:23 — forked from Bhavdip/sketch-never-ending.md
Modify Sketch to never ending trial

###Sketch trial non stop

Open hosts files:

$ open /private/etc/hosts

Edit the file adding:

127.0.0.1 backend.bohemiancoding.com

127.0.0.1 bohemiancoding.sketch.analytics.s3-website-us-east-1.amazonaws.com

@ThadeusAjayi
ThadeusAjayi / git-feature-workflow.md
Created October 17, 2017 15:56 — forked from blackfalcon/git-feature-workflow.md
Git basics - a general workflow

There are many Git workflows out there, I heavily suggest also reading the atlassian.com [Git Workflow][article] article as there is more detail then presented here.

The two prevailing workflows are [Gitflow][gitflow] and [feature branches][feature]. IMHO, being more of a subscriber to continuous integration, I feel that the feature branch workflow is better suited.

When using Bash in the command line, it leaves a bit to be desired when it comes to awareness of state. I would suggest following these instructions on [setting up GIT Bash autocompletion][git-auto].

Basic branching

When working with a centralized workflow the concepts are simple, master represented the official history and is always deployable. With each now scope of work, aka feature, the developer is to create a new branch. For clarity, make sure to use descriptive names like transaction-fail-message or github-oauth for your branches.

@ThadeusAjayi
ThadeusAjayi / str.split()
Created May 28, 2017 23:35
Alternative function to str.split() in javascript where you have have the error "TypeError: sentence.split is not a function"
function split(sentence){
var arrayPosition = 0;
var oneWord = "";
var newSentence = sentence + " ";
var split = new Array();
for(var j = 0; j < newSentence.length; j++){
if(newSentence[j] === " "){
split.push(oneWord);
arrayPosition++;
oneWord = "";