Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

lodash-contrib

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lodash-contrib - npm Package Compare versions

Comparing version 2.4.1 to 241.1.0

32

_.util.strings.js

@@ -5,3 +5,3 @@ // lodash-contrib (lodash.util.strings.js 0.0.1)

(function(root) {
(function (root) {

@@ -22,3 +22,3 @@ // Baseline setup

// Explodes a string into an array of chars
explode: function(s) {
explode: function (s) {
return s.split('');

@@ -28,3 +28,3 @@ },

// Implodes and array of chars into a string
implode: function(a) {
implode: function (a) {
return a.join('');

@@ -34,17 +34,31 @@ },

// Converts a string to camel case
camelCase : function( string ){
return string.replace(/-([a-z])/g, function (g) { return g[1].toUpperCase(); });
camelCase: function (string) {
return string.replace(/-([a-z])/g, function (g) {
return g[1].toUpperCase();
});
},
// Converts camel case to dashed (opposite of _.camelCase)
toDash : function( string ){
string = string.replace(/([A-Z])/g, function($1){return "-"+$1.toLowerCase();});
toDash: function (string) {
string = string.replace(/([A-Z])/g, function ($1) {
return "-" + $1.toLowerCase();
});
// remove first dash
return ( string.charAt( 0 ) == '-' ) ? string.substr(1) : string;
return ( string.charAt(0) == '-' ) ? string.substr(1) : string;
},
// Reports whether a string contains a search string.
strContains: function(str, search) {
strContains: function (str, search) {
if (typeof str != 'string') throw new TypeError;
return (str.indexOf(search) != -1);
},
// Reports whether a string contains a search string.
capitalize: function capitalize(string) {
return string.charAt(0).toUpperCase() + string.slice(1).toLowerCase();
},
// Slugify a string. Makes lowercase, and converts dots and spaces to dashes.
slugify: function (urlString) {
return urlString.replace(/ /g, '-').replace(/\./, '').toLowerCase();
}

@@ -51,0 +65,0 @@

{
"name": "lodash-contrib",
"version": "2.4.1",
"version": "241.1.0",
"main": "index.js",

@@ -26,8 +26,10 @@ "devDependencies": {

},
"contributors": [{
"contributors": [
{
"name": "Refael Ackermann",
"email": "refael@empeeric.com",
"url": "http://www.empeeric.com/"
}],
}
],
"homepage": "https://github.com/Empeeric/lodash-contrib"
}
SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc