@princechhikara/first-npm-package 0.0.0-stage → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -1,3 +1,50 @@
|
|
|
1
|
-
|
|
1
|
+
first-npm-package
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
A lightweight JavaScript utility to check whether a string contains at least one uppercase letter.
|
|
4
|
+
|
|
5
|
+
Installation
|
|
6
|
+
bash
|
|
7
|
+
npm install first-npm-package
|
|
8
|
+
|
|
9
|
+
Usage
|
|
10
|
+
javascript
|
|
11
|
+
const isCapitalLater = require("first-npm-package");
|
|
12
|
+
|
|
13
|
+
console.log(isCapitalLater("Hello")); // true
|
|
14
|
+
console.log(isCapitalLater("hello")); // false
|
|
15
|
+
console.log(isCapitalLater("HELLO")); // true
|
|
16
|
+
console.log(isCapitalLater("helloWORLD"));// true
|
|
17
|
+
console.log(isCapitalLater("12345")); // false
|
|
18
|
+
|
|
19
|
+
Function
|
|
20
|
+
isCapitalLater(str)
|
|
21
|
+
|
|
22
|
+
Checks whether the given string contains at least one uppercase letter.
|
|
23
|
+
|
|
24
|
+
Parameter:
|
|
25
|
+
|
|
26
|
+
str (String): The input string.
|
|
27
|
+
|
|
28
|
+
Returns:
|
|
29
|
+
|
|
30
|
+
true if the string contains an uppercase letter.
|
|
31
|
+
false if it does not.
|
|
32
|
+
Example
|
|
33
|
+
javascript
|
|
34
|
+
const isCapitalLater = require("first-npm-package");
|
|
35
|
+
|
|
36
|
+
const result = isCapitalLater("Prince");
|
|
37
|
+
|
|
38
|
+
console.log(result); // true
|
|
39
|
+
|
|
40
|
+
Testing
|
|
41
|
+
bash
|
|
42
|
+
npm test
|
|
43
|
+
|
|
44
|
+
License
|
|
45
|
+
|
|
46
|
+
MIT License
|
|
47
|
+
|
|
48
|
+
Author
|
|
49
|
+
|
|
50
|
+
Prince
|
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,19 @@
|
|
|
1
|
+
|
|
1
2
|
{
|
|
2
3
|
"name": "@princechhikara/first-npm-package",
|
|
3
|
-
"version": "
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
4
|
+
"version": "1.0.1",
|
|
5
|
+
"description": "Check whether a string contains uppercase letters",
|
|
6
|
+
"keywords": [
|
|
7
|
+
"npm",
|
|
8
|
+
"javascript",
|
|
9
|
+
"uppercase",
|
|
10
|
+
"string"
|
|
11
|
+
],
|
|
12
|
+
"license": "MIT",
|
|
13
|
+
"author": "Prince",
|
|
14
|
+
"type": "commonjs",
|
|
15
|
+
"main": "src/index.js",
|
|
16
|
+
"scripts": {
|
|
17
|
+
"test": "node --test"
|
|
18
|
+
}
|
|
19
|
+
}
|
|
Binary file
|
package/src/index.js
ADDED