Skip to content

Instantly share code, notes, and snippets.

View iiison's full-sized avatar
🤝
Together, we can!

Bharat Soni iiison

🤝
Together, we can!
  • Singapore
View GitHub Profile
@iiison
iiison / HEY-YOU.md
Created May 18, 2016 19:32 — forked from cowboy/HEY-YOU.md
jQuery Tiny Pub/Sub: A really, really, REALLY tiny pub/sub implementation for jQuery.
@iiison
iiison / NotificationSW.js
Created June 3, 2016 08:13
Notification with more than one action buttons
'use strict';
function isMobile() {
if( navigator.userAgent.match(/Android/i)
|| navigator.userAgent.match(/webOS/i)
|| navigator.userAgent.match(/iPhone/i)
|| navigator.userAgent.match(/iPad/i)
|| navigator.userAgent.match(/iPod/i)
|| navigator.userAgent.match(/BlackBerry/i)
|| navigator.userAgent.match(/Windows Phone/i)
){
@iiison
iiison / .elsintrc.js
Last active June 17, 2017 05:55
Webpack configs
let Base = {
"extends": ["airbnb", "plugin:react/recommended"],
"plugins": [
"react"
],
parser: "babel-eslint",
parserOptions: {
"ecmaVersion": 6,
"sourceType": "module",
ecmaFeatures: {
@iiison
iiison / webpack.config.babel.js
Last active December 3, 2017 16:57
Upgrading webpack 1 to 2
import webpack from 'webpack'
import path from 'path'
import ExtractTextPlugin from 'extract-text-webpack-plugin'
import HtmlWebpackPlugin from 'html-webpack-plugin'
import chalk from 'chalk'
import StyleLintPlugin from 'stylelint-webpack-plugin'
import { devStyleConfig, prodStyleConfig } from './build-configs'
const LAUNCH_COMMAND = process.env.npm_lifecycle_event
@iiison
iiison / curry.js
Last active February 7, 2017 21:24
JS Implementation of Curry
function curry(fx) {
var arity = fx.length;
var slice = Array.prototype.slice;
return function f1() {
var args = slice.call(arguments);
if (args.length >= arity) {
return fx.apply(null, args);
} else {
@iiison
iiison / index.js
Last active September 5, 2017 16:30
export devStyleConfig from './style-config-dev'
export prodStyleConfig from './style-config-prod'
@iiison
iiison / main.css
Last active September 5, 2017 17:55
/* ====================================================== *\
VENDOR - Default fall-backs and external files.
\* ====================================================== */
@import "vendor/reset";
/* ====================================================== *\
BASE - Base Variable file along with starting
point Mixins and Placeholders.
\* ====================================================== */
{
"name": "partner-portalv2",
"version": "1.0.0-0",
"description": "Partner Portal Front-End Reloaded.",
"main": "index.js",
"scripts": {
"dev": "webpack-dev-server --config webpack.config.babel.js --color --progress --hot --inline",
"test": "jest --watch --coverage",
"start": "npm-run-all dev test",
"prod": "webpack -p",
@iiison
iiison / routes.jsx
Created March 10, 2018 06:33
react routes
import React, { Component } from 'react'
import { Route, Switch, Redirect } from 'react-router-dom'
import { getCookie } from '$UTILS/cookies'
import { getUserDetails } from '$REDUX/modules/user'
import {
ConnectedLoginContainer,
ConnectedNavbarContainer,
ConnectedDashboardContainer,
ConnectedSelectStoreContainer,
[
{
"name": "CRS 4x12 ortholinear layout",
"author": "DRL https://github.com/qmk/qmk_firmware/tree/master/layouts/community/ortho_4x12/crs/",
"plate": false
},
[
{
"a": 7
},