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

word-character-count

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

word-character-count - npm Package Compare versions

Comparing version 0.1.1 to 0.1.2

2

package.json
{
"name": "word-character-count",
"version": "0.1.1",
"version": "0.1.2",
"description": "Word and character count from html5 string",

@@ -5,0 +5,0 @@ "main": "index.js",

Word and character count from html5 string.
### Why this package?
## Why this package?
Word and character count is a promise based function.
Word and character count is a **promise** based function.
### Installing
## Installing
`npm install word-character-count`
### Usage
## Usage
`const wordCount = require('word-character-count')
```javascript
const wordCount = require("word-character-count");
const result = await wordCount.WordCount('<p>This endpoint works!</p>');
`
const result = await wordCount.WordCount("<p>This endpoint works!</p>");
```
### Return object
## Return object
It returns JSON object as promise.
It returns **JSON** object as promise.
example:
`{CharacterCount: 20, WordCount: 3}`
```javascript
result = {
CharacterCount: 20,
WordCount: 3
};
```
where
WordCount and CharacterCount are both number dataType.
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