puppyid 1.0.0

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.
Files changed (3) hide show
  1. package/README.md +18 -0
  2. package/package.json +30 -0
  3. package/src/index.js +7 -0
package/README.md ADDED
@@ -0,0 +1,18 @@
1
+ # puppyid
2
+
3
+ [On npm @ https://www.npmjs.com/package/puppyid](https://www.npmjs.com/package/puppyid)
4
+
5
+ [And GitHub @ https://github.com/onlypuppy7/puppyid](https://github.com/onlypuppy7/puppyid)
6
+
7
+ Tiny thing that just makes a process ID string, ported to npm. Another useless file taken out of my projects!
8
+
9
+ ## Install
10
+ `npm install puppyid`
11
+
12
+ ## Usage
13
+ ```js
14
+ import { id, createId } from 'puppyid';
15
+
16
+ console.log(`Generated ID for this process: ${id}`);
17
+ console.log(`Some random other ID: ${createId()}`);
18
+ ```
package/package.json ADDED
@@ -0,0 +1,30 @@
1
+ {
2
+ "name": "puppyid",
3
+ "version": "1.0.0",
4
+ "description": "Lightweight utility for generating unique process and random IDs in Node.js",
5
+ "type": "module",
6
+ "main": "./src/index.js",
7
+ "exports": {
8
+ ".": "./src/index.js"
9
+ },
10
+ "keywords": [
11
+ "id",
12
+ "uuid",
13
+ "unique",
14
+ "process",
15
+ "identifier",
16
+ "random",
17
+ "nodejs",
18
+ "utility",
19
+ "puppyid"
20
+ ],
21
+ "scripts": {
22
+ "test": "node src/tests/test.js"
23
+ },
24
+ "author": "onlypuppy7",
25
+ "license": "MIT",
26
+ "dependencies": {
27
+ "node-fetch": "^3.3.2",
28
+ "puppyscrambled": "^1.0.1"
29
+ }
30
+ }
package/src/index.js ADDED
@@ -0,0 +1,7 @@
1
+ import scrambled from 'puppyscrambled';
2
+
3
+ export const createId = () => scrambled.getRandomChar() + scrambled.getRandomChar() + scrambled.getRandomChar();
4
+
5
+ export const id = createId();
6
+
7
+ export default id;