@ryuu-reinzz/haruka-lib 1.0.13 → 1.0.14

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 (2) hide show
  1. package/README.md +39 -5
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -6,8 +6,40 @@
6
6
  <b>Powerful & Lightweight WhatsApp Bot Library Extension</b>
7
7
  </p>
8
8
 
9
+ # How to use
10
+ ``` bash
11
+ npm install @ryuu-reinzz/haruka-lib@1.0.14
12
+ ```
13
+
14
+ *how to use it in JavaScript:*
15
+ ``` javascript
16
+ import haruka from "@ryuu-reinzz/haruka-lib";
17
+ import makeWASocket, {
18
+ proto,
19
+ generateWAMessageFromContent,
20
+ jidDecode,
21
+ downloadContentFromMessage,
22
+ prepareWAMessageMedia,
23
+ generateMessageID,
24
+ generateWAMessage
25
+ } from '@ryuu-reinzz/baileys';
26
+
27
+ const property = {
28
+ proto,
29
+ generateWAMessageFromContent,
30
+ jidDecode,
31
+ downloadContentFromMessage,
32
+ prepareWAMessageMedia,
33
+ generateMessageID,
34
+ generateWAMessage
35
+ };
36
+
37
+ const conn = makeWASocket({});
38
+ haruka.addProperty(conn, store, smsg, property);
39
+ ```
40
+
9
41
  ## 1. Send Order
10
- # Digunakan untuk membuat tampilan pesanan profesional atau sekedar prank orderan.
42
+ *Digunakan untuk membuat tampilan pesanan profesional atau sekedar prank orderan.*
11
43
 
12
44
  ``` javascript
13
45
  conn.sendOrder(m.chat, {
@@ -27,7 +59,7 @@ Hasil Output:
27
59
  <img src="https://api.ryuu-dev.offc.my.id/src/assest/Haruhime/sendOrder.jpg" width="300" />
28
60
 
29
61
  ## 2. Send Album
30
- # Cocok untuk mengirim katalog produk atau galeri foto tanpa memenuhi chat.
62
+ *Cocok untuk mengirim katalog produk atau galeri foto tanpa memenuhi chat.*
31
63
 
32
64
  ``` javascript
33
65
  conn.sendAlbum(m.chat, [
@@ -40,7 +72,7 @@ Hasil Output:
40
72
  <img src="https://api.ryuu-dev.offc.my.id/src/assest/Haruhime/sendAlbum.jpg" width="300" />
41
73
 
42
74
  ## 3. Send Card (Carousel)
43
- # Fitur tercanggih untuk membuat menu bot yang bisa digeser (slide) ke samping.
75
+ *Fitur tercanggih untuk membuat menu bot yang bisa digeser (slide) ke samping.*
44
76
 
45
77
  ``` javascript
46
78
  conn.sendCard(m.chat, {
@@ -61,7 +93,7 @@ conn.sendCard(m.chat, {
61
93
  <img src="https://api.ryuu-dev.offc.my.id/src/assest/Haruhime/sendCard.jpg" width="300" />
62
94
 
63
95
  ## 4. Custom Sticker
64
- # Buat stiker langsung dengan identitas bot kamu sendiri.
96
+ *Buat stiker langsung dengan identitas bot kamu sendiri.*
65
97
 
66
98
  ``` javascript
67
99
  conn.sendSticker(m.chat, {
@@ -74,7 +106,9 @@ conn.sendSticker(m.chat, {
74
106
  <img src="https://api.ryuu-dev.offc.my.id/src/assest/Haruhime/sendSticker.jpg" width="200" />
75
107
 
76
108
  ## 5. ID Mapping (LID to PN and PN to LID)
77
- ``` javascript
109
+ *Mencari LID atau Phone Number*
110
+
111
+ ``` javascript
78
112
  // Mencari LID dari nomor HP
79
113
  await conn.getLidFromPN(m, "6288246552068@s.whatsapp.net");
80
114
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ryuu-reinzz/haruka-lib",
3
- "version": "1.0.13",
3
+ "version": "1.0.14",
4
4
  "description": "Library extra for bot WhatsApp",
5
5
  "main": "main/index.js",
6
6
  "type": "module",