Skip to content

Instantly share code, notes, and snippets.

View josephajibodu's full-sized avatar
🏠
Working from home

Joseph Ajibodu josephajibodu

🏠
Working from home
View GitHub Profile
@josephajibodu
josephajibodu / 1- types.ts
Created August 14, 2022 15:30
React Navigation with TS - Part 2
// types
@josephajibodu
josephajibodu / 1- types.ts
Created August 14, 2022 08:23
React Navigation with Typescript - Part 1
declare global {
namespace ReactNavigation {
interface RootParamList extends RootStackParamList {}
}
}
export type RootStackParamList = {
Home: undefined;
Profile: undefined;
@josephajibodu
josephajibodu / 1. Swift Overview.swift
Last active July 17, 2022 22:41
Basic Overview of the Swift Programming Language
//1. Constants and Variables
// Variables - value of a variable can be changed at any point in the cod
var name = "Joseph"
name = "Joseph O." // ☑️
//Constant - value of a constant can't be changed once it's set
let lastname = "Ajibodu"
//lastname = "Another Name" // (This will give an error)
// Multiple constants/variables on the same line
@josephajibodu
josephajibodu / types.ts
Created July 8, 2022 11:54
React Navigation v6 with Typescript
import { createNativeStackNavigator, NativeStackScreenProps } from '@react-navigation/native-stack';
import { Button, View } from 'react-native';
export type RootStackParamList = {
Home: undefined;
Profile: undefined;
Settings: {
userId: number;
};
};
@josephajibodu
josephajibodu / 1. Universe.php
Last active March 9, 2022 18:08
This will be the SDK for the Universe API. So that you won't stress yourself with too much details. The second file will be in the config folder. Forget about the third code for now
<?php
namespace App\Integrations;
use App\Models\User;
use Illuminate\Support\Facades\Http;
class Universe
{
protected $apiKey;
const logger => store => next => action => {
console.log("Logging", param)
next(action)
}
export default logger;
​<?php
​namespace​ ​App​\​Traits​;
​trait​ ​HasWallet
​{
​    ​public​ ​function​ ​wallet​() {