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

string-wks

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

string-wks - npm Package Compare versions

Comparing version 1.0.5 to 1.0.7

8

package.json
{
"name": "string-wks",
"version": "1.0.5",
"version": "1.0.7",
"description": "Some string manipulation functions that I need to use commonly",

@@ -19,3 +19,7 @@ "main": "string.js",

},
"homepage": "https://github.com/weaksou/string#readme"
"homepage": "https://github.com/weaksou/string#readme",
"keywords": [
"string",
"validate-url"
]
}

@@ -1,2 +0,2 @@

# I only created this for my personnal use, it will grow up by time :)
# I created this for my personnal use, it will grow up by time :)

@@ -59,3 +59,3 @@ ## basic functions

1. **string:** text
2. **count:** how many inputs you want to output from a string
2. **count:** where to cut the string
3. **dotsCount** *(optional)***:** add three dots at the end if string length is bigger than dotsCount, if not specified default is 100 character.

@@ -72,4 +72,12 @@ >trimTo(string, count)

**trimToSimple**
return an array with two values,
1. first is: the trimed text .
2. what left in the text.
can be usefull creating ***readmore*** functionality.
trimToSimple("this is some text", 10)
> [ 'this is so', 'me text' ]

@@ -11,3 +11,4 @@ //exporting functions

validateURL,
trimTo
trimTo,
trimToSimple
};

@@ -68,1 +69,8 @@

}
function trimToSimple(string, count) {
return [
string.substring(0, count),
string.substring(count, string.length)
]
}
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