Skip to content

Instantly share code, notes, and snippets.

View deepak1556's full-sized avatar

Robo deepak1556

  • Microsoft
  • Japan
View GitHub Profile
@mathisonian
mathisonian / index.md
Last active March 22, 2023 05:31
requiring npm modules in the browser console

demo gif

The final result: require() any module on npm in your browser console with browserify

This article is written to explain how the above gif works in the chrome (and other) browser consoles. A quick disclaimer: this whole thing is a huge hack, it shouldn't be used for anything seriously, and there are probably much better ways of accomplishing the same.

Update: There are much better ways of accomplishing the same, and the script has been updated to use a much simpler method pulling directly from browserify-cdn. See this thread for details: mathisonian/requirify#5

inspiration

@haschek
haschek / .jshintrc
Created May 4, 2012 16:08
JSHint Configuration, Strict Edition
{
// --------------------------------------------------------------------
// JSHint Configuration, Strict Edition
// --------------------------------------------------------------------
//
// This is a options template for [JSHint][1], using [JSHint example][2]
// and [Ory Band's example][3] as basis and setting config values to
// be most strict:
//
// * set all enforcing options to true
@sebmarkbage
sebmarkbage / react-terminology.md
Last active January 9, 2023 22:47
React (Virtual) DOM Terminology
@addyosmani
addyosmani / notes.md
Last active August 10, 2022 03:59
Notes on streaming JS & long-term code compilation caching in Chrome

Re: http://blog.chromium.org/2015/03/new-javascript-techniques-for-rapid.html

V8 Optimisations to enable fast page startup

As mentioned in our Chromium blog post, Chrome 41 introduces support for streaming parsing of JavaScript files using the async or defer attributes. This is where the V8 parser will parse any incoming JavaScript piece-by-piece so the compiler can immediately begin compiling the AST when script loading has completed. This lets us do something useful while waiting for the page to load. Compare:

This means parsing can be removed from the critical path when loading up the page. In these cases such scripts are parsed on a separate thread as soon as the download begins, allowing parsing to complete very soon after the download has completed (milliseconds), leading to pages (potentially) loading much faster.

On the Viability of Erlang Releases and CouchDB

There has been some discussion on what versions of Erlang CouchDB should support, and what versions of Erlang are detrimental to use. Sadly there were some pretty substantial problems in the R15 line and even parts of R16 that are landmines for CouchDB. This post will describe the current state of things and make some potential recommendations on approach.

Scheduler Collapse

@joaomoreno
joaomoreno / config.xlaunch
Last active January 21, 2021 03:11
Selfhosting VS Code on WSL
<?xml version="1.0" encoding="UTF-8"?>
<XLaunch WindowMode="MultiWindow" ClientMode="NoClient" LocalClient="False" Display="0" LocalProgram="xcalc" RemoteProgram="xterm" RemotePassword="" PrivateKey="" RemoteHost="" RemoteUser="" XDMCPHost="" XDMCPBroadcast="False" XDMCPIndirect="False" Clipboard="True" ClipboardPrimary="True" ExtraParams="" Wgl="True" DisableAC="True" XDMCPTerminate="False"/>
@boopathi
boopathi / attack.go
Last active December 19, 2015 23:09
A webpage was trying to get users login details of gmail. So I thought I would just play around. Find the url from the code
package main
import (
"fmt"
"net/http"
"net/url"
"time"
)
type A struct {
@indutny
indutny / vock_challenge.md
Created August 31, 2012 19:45
A Challenge

Challenge

So you're mad opensource hacker, spent days and nights working with node.js and/or network protocols. Time to show other people how cool you are!

This file describes all logic of Vock's peer-to-peer protocol (which works over UDP). And there's an issue hidden behind it's lines. Find it, fix it or just get into hacking on Vock - and you'll be awarded! Your name will be in github project's readme and I'll mention your on my twitter account.

Cheers,

Fedor Indutny (https://github.com/indutny)

@addyosmani
addyosmani / resources.md
Last active August 29, 2015 14:00
Polymer resources for FITC

Web Components Can Do That?! extras

Thanks a ton for coming down to my talk, folks <33z. Your energy was amazing. This page has a few extra resources for you.

Slides

http://addyosmani.github.io/fitc-wccdt/