Skip to content

Instantly share code, notes, and snippets.

View Parables's full-sized avatar
💭
Contributing to Open Source projects... #GivingBack2éCommunity

Parables Boltnoel Parables

💭
Contributing to Open Source projects... #GivingBack2éCommunity
  • Ghana
View GitHub Profile
@Parables
Parables / dateFormat.js
Last active August 16, 2020 06:28
Format date using tokens without any 3rd party libraries
let days = [
{ s: 'Sun', l: 'Sunday' },
{ s: 'Mon', l: "Monday" },
{ s: 'Tue', l: 'Tuesday' },
{ s: 'Wed', l: 'Wednesday' },
{ s: 'Thu', l: 'Thursday' },
{ s: 'Fri', l: 'Friday' },
{ s: 'Sat', l: 'Saturday' }
];
@Parables
Parables / clipboard.history.json
Last active July 31, 2020 23:59
idelmis-kryztalina-sync
{
"version": 2,
"clips": [
{
"value": "app",
"createdAt": 1591673877303,
"copyCount": 1,
"useCount": 0,
"language": "typescript",
"createdLocation": {
@Parables
Parables / main.cpp
Last active June 13, 2020 00:40
BMI calc
#include <iostream>
#include <string>
#include <cstring>
#include <sstream>
#include <iomanip>
using namespace std;
//
typedef struct{
double bmiValue;
@Parables
Parables / geyser.txt
Last active June 6, 2020 10:08
C++ Geyser Program
1 3.6 79
2 1.8 54
3 3.333 74
4 2.283 62
5 4.533 85
6 2.883 55
7 4.7 88
8 3.6 85
9 1.95 51
10 4.35 85
@Parables
Parables / index.ts
Created May 19, 2020 11:07
hapi cookie authentication
const Hapi = require('@hapi/hapi');
const bcrypt = require('bcrypt');
import { User, UserType } from './model';
import connectDB, { user, createUser, updateUser } from './controller'
const init = async () => {
var server = Hapi.server({
port: process.env.PORT || 3000,
host: process.env.HOST || '0.0.0.0' || 'localhost',
@Parables
Parables / main.cpp
Last active April 23, 2020 07:34
C++ GPA Result Generator
// Example program
#include <iostream>
#include <string>
#include <iomanip>
using namespace std;
// Data Structures
typedef struct{
string title;
@Parables
Parables / index.html
Created April 21, 2020 16:25
Get random quotes
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>