Skip to content

Instantly share code, notes, and snippets.

View painkkiller's full-sized avatar
🎯
Focusing

Dmitry painkkiller

🎯
Focusing
View GitHub Profile
@painkkiller
painkkiller / AllUnderscoreMethods.js
Created June 19, 2018 15:35 — forked from alexhawkins/AllUnderscoreMethods.js
Basic Implementation of 'most' Underscore Methods from Scratch
var _ = {};
/*********IDENTITY**********/
_.identity = function(val) {
return val;
};
/*********FIRST**********/
_.first = function(array, n) {
const express = require('express');
const app = express();
app.post('/file', (req, res, next) => {
let first = true;
req.on('data', chunk => {
if (!first) {
return;
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import Dropzone from 'react-dropzone';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
import styles from './FileUploader.styl';
import FileIcon from '../../FileIcon/index';
import {
uploadAttachments,