Instantly share code, notes, and snippets.

View acl.js
// users
const users = [
{
id: 0,
name: "Rocky"
},
{
id: 1,
name: "John"
},
View file.js
// User details
// https://www.instagram.com/<username>/?__a=1
// Feed
// https://www.instagram.com/explore/tags/<tag>/?__a=1&max_id=<endcursor>
View react-test.js
import React from 'react';
import { Provider, connect } from 'react-redux';
import { combineReducers, createStore, applyMiddleware } from 'redux'
import { render } from 'react-dom';
import thunk from 'redux-thunk'
import { createLogger } from 'redux-logger'
import PropTypes from 'prop-types'
import registerServiceWorker from './registerServiceWorker';
View test.js
/*
Project: angular-gantt v1.2.11 - Gantt chart component for AngularJS
Authors: Marco Schweighauser, Rémi Alvergnat
License: MIT
Homepage: https://www.angular-gantt.com
Github: https://github.com/angular-gantt/angular-gantt.git
*/
!function(){"use strict";angular.module("gantt",["gantt.templates","angularMoment"]).directive("gantt",["Gantt","ganttEnableNgAnimate","$timeout","$templateCache",function(a,b,c,d){return{restrict:"A",transclude:!0,templateUrl:function(a,b){var c;return c=void 0===b.templateUrl?"template/gantt.tmpl.html":b.templateUrl,void 0!==b.template&&d.put(c,b.template),c},scope:{sortMode:"=?",filterTask:"=?",filterTaskComparator:"=?",filterRow:"=?",filterRowComparator:"=?",viewScale:"=?",columnWidth:"=?",expandToFit:"=?",shrinkToFit:"=?",showSide:"=?",allowSideResizing:"=?",fromDate:"=?",toDate:"=?",currentDateValue:"=?",currentDate:"=?",daily:"=?",autoExpand:"=?",taskOutOfRange:"=?",taskContent:"=?",rowContent:"=?",maxHeight:"=?",sideWidth:"=?",headers:"=?",headersFormats:"=?",timeFrames:"=
View npm-extended.md
# adduser/login
# verifies the account with existing username or creates a new one
npm adduser

# logout
# logs out the current npm user
npm logout

# bin
View npm-getting-started.md

NPM

Makes it easy to share and reuse the code(packages) that other developers have written.

Semantic versioning

A standard to communicate the kind of changes that are there in a particular release.

Generally, a version would be in the form of Major.Minor.Patch i.e. 1.0.0

  • Bug fixes and other minor changes: Patch release, increment the last number, e.g. 1.0.1
    • One can specify a patch release for let say 1.0.4 by 1.0/1.0.x/~1.0.4
  • New features which don't break existing features: Minor release, increment the middle number, e.g. 1.1.0
View curl
curl -v -X POST --data "@WCLMAT-v1.xlsx" -H "Content-Type:multipart/form-data" --cookie "userId=USR3558934016" http://localhost:9000/products/upload
View Hello.scala
// Example 0. Class Inheritance
class A {
def f() = println("I'm f from A")
}
val a = new A
a.f
View grunt-sass.js
module.exports = function(grunt) {
grunt.initConfig({
sass: {
dist: {
options: {
style: 'expanded',
loadPath: ['bower_components/foundation/scss']
},
files: {
View mybackbone.js
// lawl will be the namespace for this framework.
(function (root, factory) {
if (typeof define === 'function' && define.amd) {
define(factory);
} else if (typeof exports === 'object') {
module.exports = factory;
} else {
root.lawl = factory(root);
}