Socket
Socket
Sign inDemoInstall

gen-pasta

Package Overview
Dependencies
0
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    gen-pasta

A collection of general functions that I have found myself copy pastaing around.


Version published
Weekly downloads
2
decreased by-71.43%
Maintainers
1
Install size
4.55 kB
Created
Weekly downloads
 

Readme

Source

#General Pasta

A collection of general functions that I have found myself copy pastaing around.

I am trying to separate the pasta into useful strands.

##log()

Takes any number of args and logs them if it can.

##slice(obj[, start, end])

Take an array like object and return a real array. Optional start/end.

##combine(obj1, obj2)

Add everything from obj2 into obj1 and return obj1.

##last(item)

Attempt to return the last element from item, whatever item might be.

##first(item)

Attempt to return the first element from item, whatever item might be.

##flatten(arr)

Steamrolls nested arrays into a string.

FAQs

Last updated on 07 Feb 2013

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc