Skip to content

Instantly share code, notes, and snippets.

View aleyrizvi's full-sized avatar

Asad Rizvi aleyrizvi

View GitHub Profile
@aleyrizvi
aleyrizvi / index.js
Created September 10, 2019 13:58
Winston-sms example
let winston = require('winston')
let winstonSms = require('winston-sms')
var logger = winston.CreateLogger({
//Your custom configurations
// refer to https://github.com/winstonjs/winston#creating-your-own-logger
transports: [
new winstonSms({
username: 'your_nomado_username',
password: 'your_nomado_password',
@aleyrizvi
aleyrizvi / main.js
Last active December 23, 2020 19:50
const nomadoClient = require('nomado');
const nomado = new nomadoClient({'USERNAME', 'PASSWORD'});
const smsOptions = {
to: ['3245678901'],
message: 'Hello world',
unicode: false
};
@aleyrizvi
aleyrizvi / helloworld.php
Created October 27, 2022 08:59
Bug free code - Perfect example of how to write bug free code in php with confidence.
<?php
?>
@aleyrizvi
aleyrizvi / TablerIcon.tsx
Last active January 16, 2023 10:12
Dynamic Tabler Icons import for react
import * as icons from "@tabler/icons"
interface Props {
icon: string
color?: string
size?: number
stroke?: number
}
export const TablerIcons = (props: Props): JSX.Element => {
@aleyrizvi
aleyrizvi / icons.js
Created February 25, 2023 18:26
Dynamic TablerIcons without loading all icons
import {IconAward, IconBrandAmazon, IconBrandAdobe} from "@tabler/icons-react"
export const TablerIcons = (props) => {
const { icon, color = "gray", size = 6, stroke = 2 } = props
const icons = {
"IconAward" : IconAward,
"IconBrandAmazon": IconBrandAmazon,
"IconBrandAdobe": IconBrandAdobe