Skip to content

Instantly share code, notes, and snippets.

👨‍💻
Trying Really Hard

Praveen Puglia praveenpuglia

👨‍💻
Trying Really Hard
Block or report user

Report or block praveenpuglia

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@iambibhas
iambibhas / facebook_url_redirect_avoid.js
Last active Nov 20, 2015
UserScript to avoid Facebook's URL director
View facebook_url_redirect_avoid.js
// ==UserScript==
// @name Facebook URL Redirector Bypass
// @namespace in.bibhas
// @include https://*.facebook.com/*
// @version 1
// @grant none
// ==/UserScript==
si = window.setInterval(clearanchors, 2000);
function clearanchors(){
anchors = document.getElementsByTagName('a');
@praveenpuglia
praveenpuglia / debug.component.ts
Created Mar 23, 2018
Simple Component that dumps prettified data in any template.
View debug.component.ts
import { Component, Input } from '@angular/core';
@Component({
selector: 'dump',
template: `
<pre><code>{{data | json}}</code></pre>
`,
styles: [
`
:host {
@praveenpuglia
praveenpuglia / webpack.config.js
Last active Apr 11, 2018
Simplest webpack 4 configuration to work with vuejs & scss
View webpack.config.js
// Require things!
const path = require('path');
const webpack = require('webpack');
const HtmlWebpackPlugin = require('html-webpack-plugin');
// The configuration starts here!
module.exports = {
// The entry point for webpack to start generating a dependency graph.
entry: { index: './src/index.js' },
@tovbinm
tovbinm / gist:2975609
Created Jun 22, 2012
Remove the “Last login” message from the Mac OS X Terminal
View gist:2975609
Remove:
touch .hushlogin
Get it back:
rm .hushlogin
@bradens
bradens / slack-dark-theme.css
Last active Feb 1, 2019
Dark theme for slack
View slack-dark-theme.css
#msgs_scroller_div::-webkit-scrollbar-track, #client_body::before, .client_container,
#search_terms, #client_body, #footer, ts-message, .channel_header, ts-jumper ts-jumper-container,
ts-jumper input[type="text"] {
background: #282c34 !important;
}
#client_body::before {
border-bottom: 1px solid #1a2129 !important;
}
@torgeir
torgeir / gulpfile.js
Last active Apr 2, 2019 — forked from markgoodyear/01-gulpfile.js
Example gulpfile.js
View gulpfile.js
// Load plugins
var gulp = require('gulp'),
sass = require('gulp-ruby-sass'),
autoprefixer = require('gulp-autoprefixer'),
minifycss = require('gulp-minify-css'),
jshint = require('gulp-jshint'),
uglify = require('gulp-uglify'),
imagemin = require('gulp-imagemin'),
rename = require('gulp-rename'),
clean = require('gulp-clean'),
@mikaelbr
mikaelbr / gulpfile.js
Created Jan 14, 2014
Example gulpfile for complete set-up.
View gulpfile.js
var gulp = require('gulp');
var browserify = require('gulp-browserify');
var concat = require('gulp-concat');
var less = require('gulp-less');
var refresh = require('gulp-livereload');
var lr = require('tiny-lr');
var server = lr();
var minifyCSS = require('gulp-minify-css');
var embedlr = require('gulp-embedlr');
@MarkTiedemann
MarkTiedemann / README.md
Last active Mar 3, 2020
An Easier Way to Enforce Required Parameters in ES6
View README.md

An Easier Way to Enforce Required Parameters in ES6

Expands on Handling required parameters in ECMAScript 6 by Axel Rauschmayer.

The idea (which is credited to Allen Wirfs-Brock) is, in essence, to use default parameter values to call a function which throws an Error if the parameter is missing:

const throwIfMissing () => { throw new Error('Missing parameter') }
@candycode
candycode / image-arraybuffer.js
Created Mar 7, 2014
Create a jpg image from ArrayBuffer data
View image-arraybuffer.js
// Simulate a call to Dropbox or other service that can
// return an image as an ArrayBuffer.
var xhr = new XMLHttpRequest();
// Use JSFiddle logo as a sample image to avoid complicating
// this example with cross-domain issues.
xhr.open( "GET", "http://fiddle.jshell.net/img/logo.png", true );
// Ask for the result as an ArrayBuffer.
xhr.responseType = "arraybuffer";
@trey
trey / git-commit-author-rewrite.md
Last active Mar 13, 2020
Change the email address for a git commit.
View git-commit-author-rewrite.md

Change the email address for a git commit.

$ git commit --amend --author="Author Name <email@address.com>"

or

$ git commit --amend --reset-author
You can’t perform that action at this time.