Sign Up for Free

RunKit +

Try any Node.js package right in your browser

This is a playground to test code. It runs a full Node.js environment and already has all of npm’s 400,000 packages pre-installed, including stack-overflow-copy-paste with all npm packages installed. Try it out:

var stackOverflowCopyPaste = require("stack-overflow-copy-paste")

This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.

stack-overflow-copy-paste v1.94.0

Utility functions copy/pasted (and modified slightly) from Stack Overflow

stack-overflow-copy-paste

A collection of utility JavaScript functions copy/pasted and slightly modified from StackOverflow answers 😀 (Not intended to be used in actual programs)

travis build codecov coverage version downloads MIT License semantic-release PRs Welcome Commitizen friendly

This repo is used as the basis for an Egghead.io series entitled: How to Contribute to an Open Source Project on GitHub

This repository exists as a resource for people to learn how to contribute to open source in a safe and friendly environment. Feel free to watch the video series and then contribute to this project. See the contributing guidelines.

Usage

import {flatten, snakeToCamel, clone} from 'stack-overflow-copy-paste'

flatten([[1, 2,], 3]) // [1, 2, 3]
snakeToCamel('snake-case-string') // 'snakeCaseString'

const testObj = {a: 1, b: 2}
const copyObj = clone(testObj)

LICENSE

MIT

RunKit is a free, in-browser JavaScript dev environment for prototyping Node.js code, with every npm package installed. Sign up to share your code.
Sign Up for Free