taraskevizer 1.0.0 → 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.
Files changed (2) hide show
  1. package/README.md +13 -3
  2. package/package.json +4 -2
package/README.md CHANGED
@@ -4,7 +4,6 @@
4
4
  $ npm i taraskevizer
5
5
  ```
6
6
 
7
-
8
7
  ## Usage
9
8
 
10
9
  ```js
@@ -18,18 +17,23 @@ const result = await tarask(text);
18
17
  ## API
19
18
 
20
19
  ### tarask(text, options?)
20
+
21
21
  Returns a `Promise<string>`
22
22
 
23
23
  ### taraskSync(text, options?)
24
+
24
25
  Returns a `string`
25
26
 
26
27
  #### text
28
+
27
29
  Type: `string`
28
30
 
29
31
  ## Options
32
+
30
33
  Type: `object`
31
34
 
32
35
  ### abc
36
+
33
37
  Type: `number`
34
38
 
35
39
  Default value: `0`
@@ -40,6 +44,7 @@ Alphabet of output text:
40
44
  2. arabic
41
45
 
42
46
  ### j
47
+
43
48
  Type: `number`
44
49
 
45
50
  Default value: `0`
@@ -50,6 +55,7 @@ When to replace `і`(`i`) by `й`(`j`) after vowels:
50
55
  2. always
51
56
 
52
57
  ### html
58
+
53
59
  Type: `false|object`
54
60
 
55
61
  Default value: `false`
@@ -57,19 +63,21 @@ Default value: `false`
57
63
  If `object`, some parts of a text are wrapped in HTML tags.
58
64
 
59
65
  #### g
66
+
60
67
  Type: `boolean`
61
68
 
62
69
  Default value: `false`
63
70
 
64
71
  Do replace `г`(`h`) by `ґ`(`g`) in cyrillic alphabet?
72
+
65
73
  ```html
66
- false: <tarH>г</tarH> <tarH>Г</tarH>
67
- true: <tarH>ґ</tarH> <tarH>Ґ</tarH>
74
+ false: <tarH>г</tarH> <tarH>Г</tarH> true: <tarH>ґ</tarH> <tarH>Ґ</tarH>
68
75
  ```
69
76
 
70
77
  ## HTML tags
71
78
 
72
79
  ### tarF
80
+
73
81
  Difference between an input and an output word.
74
82
 
75
83
  ```html
@@ -79,6 +87,7 @@ Difference between an input and an output word.
79
87
  ```
80
88
 
81
89
  ### tarL
90
+
82
91
  A part of a word wrapped in this tag is variable,
83
92
  variations are mentioned in a `data-l` attribute
84
93
  and are separated by commas
@@ -90,6 +99,7 @@ and are separated by commas
90
99
  ```
91
100
 
92
101
  ### tarH
102
+
93
103
  Can be replaced by `ґ`(`g`) letter. appears only if alphabet is cyrillic
94
104
 
95
105
  ```html
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "taraskevizer",
3
3
  "author": "GooseOb",
4
4
  "license": "MIT",
5
- "version": "1.0.0",
5
+ "version": "1.0.1",
6
6
  "private": false,
7
7
  "homepage": "https://gooseob.github.io/taraskevizatar/",
8
8
  "main": "dist/index.js",
@@ -13,7 +13,8 @@
13
13
  "README.md"
14
14
  ],
15
15
  "scripts": {
16
- "build": "tsup --config build-config/index.js"
16
+ "build": "tsup --config build-config/index.js",
17
+ "prepare": "husky install"
17
18
  },
18
19
  "repository": {
19
20
  "type": "git",
@@ -27,6 +28,7 @@
27
28
  "belarusian"
28
29
  ],
29
30
  "devDependencies": {
31
+ "husky": "^8.0.3",
30
32
  "prettier": "^3.0.0",
31
33
  "tsup": "^6.5.0",
32
34
  "typescript": "^4.9.4"