data-structure-typed 1.33.2 → 1.33.6

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 (148) hide show
  1. package/{.eslintrc.json → .eslintrc.js} +2 -1
  2. package/.github/workflows/ci.yml +15 -3
  3. package/.github/workflows/release-package.yml +32 -0
  4. package/{.prettierrc → .prettierrc.js} +1 -1
  5. package/CHANGELOG.md +5 -1
  6. package/README.md +2 -3
  7. package/coverage/coverage-final.json +64 -64
  8. package/coverage/coverage-summary.json +2 -2
  9. package/dist/data-structures/graph/abstract-graph.js +12 -12
  10. package/dist/data-structures/graph/abstract-graph.js.map +1 -1
  11. package/dist/data-structures/priority-queue/priority-queue.js +6 -6
  12. package/dist/data-structures/priority-queue/priority-queue.js.map +1 -1
  13. package/docs/index.html +2 -3
  14. package/package.json +68 -60
  15. package/src/data-structures/binary-tree/aa-tree.ts +1 -0
  16. package/src/data-structures/binary-tree/abstract-binary-tree.ts +1608 -0
  17. package/src/data-structures/binary-tree/avl-tree.ts +307 -0
  18. package/src/data-structures/binary-tree/b-tree.ts +1 -0
  19. package/src/data-structures/binary-tree/binary-indexed-tree.ts +76 -0
  20. package/src/data-structures/binary-tree/binary-tree.ts +47 -0
  21. package/src/data-structures/binary-tree/bst.ts +537 -0
  22. package/src/data-structures/binary-tree/index.ts +12 -0
  23. package/src/data-structures/binary-tree/rb-tree.ts +366 -0
  24. package/src/data-structures/binary-tree/segment-tree.ts +242 -0
  25. package/src/data-structures/binary-tree/splay-tree.ts +1 -0
  26. package/src/data-structures/binary-tree/tree-multiset.ts +700 -0
  27. package/src/data-structures/binary-tree/two-three-tree.ts +1 -0
  28. package/src/data-structures/graph/abstract-graph.ts +1040 -0
  29. package/src/data-structures/graph/directed-graph.ts +470 -0
  30. package/src/data-structures/graph/index.ts +4 -0
  31. package/src/data-structures/graph/map-graph.ts +129 -0
  32. package/src/data-structures/graph/undirected-graph.ts +274 -0
  33. package/src/data-structures/hash/coordinate-map.ts +67 -0
  34. package/src/data-structures/hash/coordinate-set.ts +56 -0
  35. package/src/data-structures/hash/hash-table.ts +157 -0
  36. package/src/data-structures/hash/index.ts +6 -0
  37. package/src/data-structures/hash/pair.ts +1 -0
  38. package/src/data-structures/hash/tree-map.ts +1 -0
  39. package/src/data-structures/hash/tree-set.ts +1 -0
  40. package/src/data-structures/heap/heap.ts +212 -0
  41. package/src/data-structures/heap/index.ts +3 -0
  42. package/src/data-structures/heap/max-heap.ts +31 -0
  43. package/src/data-structures/heap/min-heap.ts +32 -0
  44. package/src/data-structures/index.ts +11 -0
  45. package/src/data-structures/linked-list/doubly-linked-list.ts +636 -0
  46. package/src/data-structures/linked-list/index.ts +3 -0
  47. package/src/data-structures/linked-list/singly-linked-list.ts +501 -0
  48. package/src/data-structures/linked-list/skip-linked-list.ts +1 -0
  49. package/src/data-structures/matrix/index.ts +4 -0
  50. package/src/data-structures/matrix/matrix.ts +27 -0
  51. package/src/data-structures/matrix/matrix2d.ts +213 -0
  52. package/src/data-structures/matrix/navigator.ts +121 -0
  53. package/src/data-structures/matrix/vector2d.ts +316 -0
  54. package/src/data-structures/priority-queue/index.ts +3 -0
  55. package/src/data-structures/priority-queue/max-priority-queue.ts +56 -0
  56. package/src/data-structures/priority-queue/min-priority-queue.ts +57 -0
  57. package/src/data-structures/priority-queue/priority-queue.ts +359 -0
  58. package/src/data-structures/queue/deque.ts +297 -0
  59. package/src/data-structures/queue/index.ts +2 -0
  60. package/src/data-structures/queue/queue.ts +191 -0
  61. package/src/data-structures/stack/index.ts +1 -0
  62. package/src/data-structures/stack/stack.ts +98 -0
  63. package/src/data-structures/tree/index.ts +1 -0
  64. package/src/data-structures/tree/tree.ts +69 -0
  65. package/src/data-structures/trie/index.ts +1 -0
  66. package/src/data-structures/trie/trie.ts +225 -0
  67. package/src/index.ts +4 -0
  68. package/src/interfaces/abstract-binary-tree.ts +189 -0
  69. package/src/interfaces/abstract-graph.ts +31 -0
  70. package/src/interfaces/avl-tree.ts +25 -0
  71. package/src/interfaces/binary-tree.ts +6 -0
  72. package/src/interfaces/bst.ts +31 -0
  73. package/src/interfaces/directed-graph.ts +20 -0
  74. package/src/interfaces/doubly-linked-list.ts +1 -0
  75. package/src/interfaces/heap.ts +1 -0
  76. package/src/interfaces/index.ts +15 -0
  77. package/src/interfaces/navigator.ts +1 -0
  78. package/src/interfaces/priority-queue.ts +1 -0
  79. package/src/interfaces/rb-tree.ts +9 -0
  80. package/src/interfaces/segment-tree.ts +1 -0
  81. package/src/interfaces/singly-linked-list.ts +1 -0
  82. package/src/interfaces/tree-multiset.ts +7 -0
  83. package/src/interfaces/undirected-graph.ts +6 -0
  84. package/src/types/data-structures/abstract-binary-tree.ts +50 -0
  85. package/src/types/data-structures/abstract-graph.ts +11 -0
  86. package/src/types/data-structures/avl-tree.ts +5 -0
  87. package/src/types/data-structures/binary-tree.ts +5 -0
  88. package/src/types/data-structures/bst.ts +13 -0
  89. package/src/types/data-structures/directed-graph.ts +8 -0
  90. package/src/types/data-structures/doubly-linked-list.ts +1 -0
  91. package/src/types/data-structures/heap.ts +5 -0
  92. package/src/types/data-structures/index.ts +15 -0
  93. package/src/types/data-structures/map-graph.ts +1 -0
  94. package/src/types/data-structures/navigator.ts +13 -0
  95. package/src/types/data-structures/priority-queue.ts +9 -0
  96. package/src/types/data-structures/rb-tree.ts +8 -0
  97. package/src/types/data-structures/segment-tree.ts +1 -0
  98. package/src/types/data-structures/singly-linked-list.ts +1 -0
  99. package/src/types/data-structures/tree-multiset.ts +6 -0
  100. package/src/types/helpers.ts +1 -0
  101. package/src/types/index.ts +3 -0
  102. package/src/types/utils/index.ts +2 -0
  103. package/src/types/utils/utils.ts +6 -0
  104. package/src/types/utils/validate-type.ts +35 -0
  105. package/src/utils/index.ts +1 -0
  106. package/src/utils/utils.ts +79 -0
  107. package/test/integration/avl-tree.test.ts +14 -17
  108. package/test/integration/bst.test.ts +50 -41
  109. package/test/integration/heap.test.js +0 -3
  110. package/test/unit/data-structures/binary-tree/avl-tree.test.ts +14 -17
  111. package/test/unit/data-structures/binary-tree/binary-tree.test.ts +0 -4
  112. package/test/unit/data-structures/binary-tree/bst.test.ts +50 -41
  113. package/test/unit/data-structures/binary-tree/overall.test.ts +36 -28
  114. package/test/unit/data-structures/binary-tree/rb-tree.test.ts +0 -1
  115. package/test/unit/data-structures/binary-tree/tree-multiset.test.ts +23 -12
  116. package/test/unit/data-structures/graph/directed-graph.test.ts +27 -25
  117. package/test/unit/data-structures/graph/map-graph.test.ts +4 -5
  118. package/test/unit/data-structures/graph/overall.test.ts +10 -11
  119. package/test/unit/data-structures/graph/undirected-graph.test.ts +0 -1
  120. package/test/unit/data-structures/heap/heap.test.ts +7 -8
  121. package/test/unit/data-structures/heap/max-heap.test.ts +7 -5
  122. package/test/unit/data-structures/heap/min-heap.test.ts +6 -5
  123. package/test/unit/data-structures/linked-list/doubly-linked-list.test.ts +9 -10
  124. package/test/unit/data-structures/linked-list/linked-list.test.ts +1 -1
  125. package/test/unit/data-structures/linked-list/singly-linked-list.test.ts +4 -7
  126. package/test/unit/data-structures/linked-list/skip-linked-list.test.ts +3 -3
  127. package/test/unit/data-structures/matrix/matrix.test.ts +4 -4
  128. package/test/unit/data-structures/matrix/navigator.test.ts +4 -5
  129. package/test/unit/data-structures/priority-queue/max-priority-queue.test.ts +5 -7
  130. package/test/unit/data-structures/priority-queue/min-priority-queue.test.ts +13 -13
  131. package/test/unit/data-structures/priority-queue/priority-queue.test.ts +8 -8
  132. package/test/unit/data-structures/queue/deque.test.ts +0 -1
  133. package/test/unit/data-structures/queue/queue.test.ts +1 -5
  134. package/test/unit/data-structures/trie/trie.test.ts +2 -2
  135. package/test/utils/magnitude.ts +3 -3
  136. package/tsconfig.json +3 -12
  137. package/tsconfig.prod.json +25 -0
  138. package/.auto-changelog +0 -9
  139. package/.gitattributes +0 -112
  140. package/.idea/codeStyles/Project.xml +0 -61
  141. package/.idea/codeStyles/codeStyleConfig.xml +0 -5
  142. package/.idea/data-structure-typed.iml +0 -19
  143. package/.idea/inspectionProfiles/Project_Default.xml +0 -6
  144. package/.idea/misc.xml +0 -6
  145. package/.idea/modules.xml +0 -8
  146. package/.idea/vcs.xml +0 -6
  147. package/.prettierignore +0 -6
  148. package/webpack.config.js +0 -28
@@ -1,7 +1,6 @@
1
1
  import {MinPriorityQueue, PriorityQueue} from '../../../../src';
2
2
 
3
3
  describe('MinPriorityQueue Operation Test', () => {
4
-
5
4
  it('should check if a node exists in the queue', () => {
6
5
  const priorityQueue = new MinPriorityQueue<number>();
7
6
  priorityQueue.add(5);
@@ -20,7 +19,6 @@ describe('MinPriorityQueue Operation Test', () => {
20
19
  expect(priorityQueue.size).toBe(3);
21
20
  });
22
21
 
23
-
24
22
  it('should return the last element', () => {
25
23
  const priorityQueue = new MinPriorityQueue<number>();
26
24
  priorityQueue.add(5);
@@ -52,7 +50,6 @@ describe('MinPriorityQueue Operation Test', () => {
52
50
  expect(priorityQueue.isEmpty()).toBe(true);
53
51
  });
54
52
 
55
-
56
53
  it('should sort the elements', () => {
57
54
  const priorityQueue = new MinPriorityQueue<number>();
58
55
  priorityQueue.add(5);
@@ -72,10 +69,12 @@ describe('MinPriorityQueue Operation Test', () => {
72
69
  minPQ.poll();
73
70
  expect(minPQ.toArray()).toEqual([4, 5, 6]);
74
71
  expect(minPQ.peek()).toBe(4);
75
- expect(PriorityQueue.heapify({
76
- nodes: [3, 2, 1, 5, 6, 7, 8, 9, 10],
77
- comparator: (a, b) => a - b
78
- }).toArray()).toEqual([1, 2, 3, 5, 6, 7, 8, 9, 10]);
72
+ expect(
73
+ PriorityQueue.heapify({
74
+ nodes: [3, 2, 1, 5, 6, 7, 8, 9, 10],
75
+ comparator: (a, b) => a - b
76
+ }).toArray()
77
+ ).toEqual([1, 2, 3, 5, 6, 7, 8, 9, 10]);
79
78
  });
80
79
 
81
80
  it('should Max PriorityQueue poll, peek, heapify, toArray work well', function () {
@@ -86,20 +85,21 @@ describe('MinPriorityQueue Operation Test', () => {
86
85
  maxPriorityQueue.poll();
87
86
  expect(maxPriorityQueue.toArray()).toEqual([3, 2, 1]);
88
87
  expect(maxPriorityQueue.peek()).toBe(3);
89
- expect(PriorityQueue.heapify({
90
- nodes: [3, 2, 1, 5, 6, 7, 8, 9, 10],
91
- comparator: (a, b) => a - b
92
- }).toArray()).toEqual([1, 2, 3, 5, 6, 7, 8, 9, 10]);
88
+ expect(
89
+ PriorityQueue.heapify({
90
+ nodes: [3, 2, 1, 5, 6, 7, 8, 9, 10],
91
+ comparator: (a, b) => a - b
92
+ }).toArray()
93
+ ).toEqual([1, 2, 3, 5, 6, 7, 8, 9, 10]);
93
94
  });
94
95
 
95
96
  it('should PriorityQueue clone, sort, getNodes, DFS work well', function () {
96
97
  const minPQ1 = new PriorityQueue<number>({nodes: [2, 5, 8, 3, 1, 6, 7, 4], comparator: (a, b) => a - b});
97
98
  const clonedPriorityQueue = minPQ1.clone();
98
99
  expect(clonedPriorityQueue.getNodes()).toEqual(minPQ1.getNodes());
99
- expect(clonedPriorityQueue.sort()).toEqual([1, 2, 3, 4, 5, 6, 7, 8])
100
+ expect(clonedPriorityQueue.sort()).toEqual([1, 2, 3, 4, 5, 6, 7, 8]);
100
101
  expect(minPQ1.DFS('in')).toEqual([4, 3, 2, 5, 1, 8, 6, 7]);
101
102
  expect(minPQ1.DFS('post')).toEqual([4, 3, 5, 2, 8, 7, 6, 1]);
102
103
  expect(minPQ1.DFS('pre')).toEqual([1, 2, 3, 4, 5, 6, 8, 7]);
103
104
  });
104
-
105
105
  });
@@ -2,26 +2,26 @@ import {PriorityQueue} from '../../../../src';
2
2
  import {getRandomInt} from '../../../utils';
3
3
 
4
4
  describe('PriorityQueue Operation Test', () => {
5
-
6
5
  it('should validate a priority queue', () => {
7
6
  const minPQ = new PriorityQueue<number>({nodes: [1, 5, 7, 9, 3, 6, 2], comparator: (a, b) => a - b});
8
7
 
9
8
  expect(minPQ.isValid()).toBe(true);
10
9
  expect(PriorityQueue.isPriorityQueueified({nodes: minPQ.nodes, comparator: (a, b) => a - b})).toBe(true);
11
10
  expect(PriorityQueue.isPriorityQueueified({nodes: minPQ.nodes, comparator: (a, b) => b - a})).toBe(false);
12
- expect(PriorityQueue.isPriorityQueueified({
13
- nodes: [1, 5, 7, 9, 3, 6, 2],
14
- comparator: (a, b) => b - a
15
- })).toBe(false);
11
+ expect(
12
+ PriorityQueue.isPriorityQueueified({
13
+ nodes: [1, 5, 7, 9, 3, 6, 2],
14
+ comparator: (a, b) => b - a
15
+ })
16
+ ).toBe(false);
16
17
  });
17
-
18
18
  });
19
19
 
20
20
  describe('Priority Queue Performance Test', () => {
21
21
  it('should numeric heap work well', function () {
22
22
  const values = Array.from(new Array(10000), () => getRandomInt(1, 10000000));
23
23
  const minPriorityQueue = new PriorityQueue<number>({nodes: values, comparator: (a, b) => a - b});
24
- const sorted = minPriorityQueue.sort()
24
+ const sorted = minPriorityQueue.sort();
25
25
  expect(sorted).toEqual(values.sort((a, b) => a - b));
26
26
  });
27
- })
27
+ });
@@ -35,7 +35,6 @@ describe('Deque Tests', () => {
35
35
  expect(deque.size).toBe(2);
36
36
  });
37
37
 
38
-
39
38
  it('should handle adding and removing elements alternately', () => {
40
39
  deque.addFirst(1);
41
40
  expect(deque.pollFirst()).toBe(1);
@@ -2,7 +2,6 @@ import {Queue, LinkedListQueue} from '../../../../src';
2
2
  import {bigO, magnitude} from '../../../utils';
3
3
 
4
4
  describe('Queue Operation Test', () => {
5
-
6
5
  it('should validate a queue', () => {
7
6
  const queue = new Queue<number>();
8
7
  for (let i = 0; i < 1000; i++) {
@@ -14,7 +13,6 @@ describe('Queue Operation Test', () => {
14
13
  }
15
14
  expect(last).toBe(999);
16
15
  });
17
-
18
16
  });
19
17
 
20
18
  describe('Queue Performance Test', () => {
@@ -31,10 +29,8 @@ describe('Queue Performance Test', () => {
31
29
  }
32
30
  expect(last).toBe(magnitude.LINEAR - 1);
33
31
  expect(performance.now() - startTime).toBeLessThan(bigO.LINEAR * 100);
34
-
35
32
  });
36
- })
37
-
33
+ });
38
34
 
39
35
  describe('Queue', () => {
40
36
  let queue: Queue<number>;
@@ -1,4 +1,4 @@
1
- import { Trie, TrieNode } from '../../../../src';
1
+ import {Trie, TrieNode} from '../../../../src';
2
2
 
3
3
  describe('TrieNode', () => {
4
4
  it('should create a TrieNode with the given value', () => {
@@ -78,7 +78,7 @@ describe('Trie', () => {
78
78
  trie.add('app');
79
79
  trie.add('application');
80
80
  const words = trie.getAll('app');
81
- expect(words).toEqual(['apple', 'application','app']);
81
+ expect(words).toEqual(['apple', 'application', 'app']);
82
82
  });
83
83
 
84
84
  it('should remove words from Trie', () => {
@@ -8,14 +8,14 @@ export const magnitude = {
8
8
  SQUARED: Math.pow(10, 4 - orderReducedBy),
9
9
  CUBED: Math.pow(10, 3 - orderReducedBy),
10
10
  FACTORIAL: 20 - orderReducedBy
11
- }
11
+ };
12
12
 
13
13
  export const bigO = {
14
14
  CONSTANT: magnitude.CONSTANT / 100000,
15
15
  LOG_N: Math.log2(magnitude.LOG_N) / 1000,
16
16
  LINEAR: magnitude.LINEAR / 1000,
17
- N_LOG_N: magnitude.N_LOG_N * Math.log2(magnitude.LOG_N) / 1000,
17
+ N_LOG_N: (magnitude.N_LOG_N * Math.log2(magnitude.LOG_N)) / 1000,
18
18
  SQUARED: Math.pow(magnitude.SQUARED, 2) / 1000,
19
19
  CUBED: Math.pow(magnitude.SQUARED, 3) / 1000,
20
20
  FACTORIAL: 10000
21
- }
21
+ };
package/tsconfig.json CHANGED
@@ -2,12 +2,10 @@
2
2
  "compilerOptions": {
3
3
  "outDir": "./lib",
4
4
  "declaration": true,
5
- // "declarationDir": "./lib",
6
5
  "module": "ES6",
7
6
  "target": "ES6",
8
7
  "lib": [
9
- "esnext",
10
- "dom"
8
+ "ESNext"
11
9
  ],
12
10
  "strict": true,
13
11
  "esModuleInterop": true,
@@ -15,14 +13,6 @@
15
13
  "skipLibCheck": true,
16
14
  "downlevelIteration": true,
17
15
  "experimentalDecorators": true,
18
- // "removeComments": true,
19
- // "allowJs": true,
20
- // "allowSyntheticDefaultImports": true,
21
- // "forceConsistentCasingInFileNames": true,
22
- // "noFallthroughCasesInSwitch": true,
23
- // "resolveJsonModule": true,
24
- // "isolatedModules": true,
25
- // "noEmit": true,
26
16
  "typeRoots": [
27
17
  "node_modules/@types"
28
18
  ]
@@ -32,7 +22,8 @@
32
22
  "exclude": [
33
23
  "node_modules",
34
24
  "lib",
35
- "dist"
25
+ "dist",
26
+ "umd"
36
27
  ]
37
28
  }
38
29
 
@@ -0,0 +1,25 @@
1
+ {
2
+ "compilerOptions": {
3
+ "target": "ES5",
4
+ "module": "CommonJS",
5
+ "outDir": "./dist",
6
+ "sourceMap": true,
7
+ "lib": [
8
+ "ESNext"
9
+ ],
10
+ "strict": true,
11
+ "downlevelIteration": true,
12
+ "removeComments": true,
13
+ "typeRoots": [
14
+ "node_modules/@types"
15
+ ]
16
+ },
17
+ "include": ["src/**/*.ts", "src/**/*.js"],
18
+ "exclude": [
19
+ "node_modules",
20
+ "lib",
21
+ "dist",
22
+ "umd"
23
+ ]
24
+ }
25
+
package/.auto-changelog DELETED
@@ -1,9 +0,0 @@
1
- {
2
- "output": "CHANGELOG.md",
3
- "template": "./.auto-changelog-template.hbs",
4
- "ignoreCommitPattern": "Continuous Integration Build Artifacts",
5
- "startingVersion": "v1.3.6",
6
- "package": true,
7
- "unreleased": true,
8
- "commitLimit": false
9
- }
package/.gitattributes DELETED
@@ -1,112 +0,0 @@
1
- # Common settings that generally should always be used with your language specific settings
2
-
3
- # Auto detect text files and perform LF normalization
4
- * text=auto
5
-
6
- #
7
- # The above will handle all files NOT found below
8
- #
9
-
10
- # Documents
11
- *.bibtex text diff=bibtex
12
- *.doc diff=astextplain
13
- *.DOC diff=astextplain
14
- *.docx diff=astextplain
15
- *.DOCX diff=astextplain
16
- *.dot diff=astextplain
17
- *.DOT diff=astextplain
18
- *.pdf diff=astextplain
19
- *.PDF diff=astextplain
20
- *.rtf diff=astextplain
21
- *.RTF diff=astextplain
22
- *.md text
23
- *.tex text diff=tex
24
- *.adoc text
25
- *.textile text
26
- *.mustache text
27
- *.csv text
28
- *.tab text
29
- *.tsv text
30
- *.txt text
31
- *.sql text
32
-
33
- # Graphics
34
- *.png binary
35
- *.jpg binary
36
- *.jpeg binary
37
- *.gif binary
38
- *.tif binary
39
- *.tiff binary
40
- *.ico binary
41
- # SVG treated as an asset (binary) by default.
42
- *.svg text
43
- # If you want to treat it as binary,
44
- # use the following line instead.
45
- # *.svg binary
46
- *.eps binary
47
-
48
- # Scripts
49
- *.bash text eol=lf
50
- *.fish text eol=lf
51
- *.sh text eol=lf
52
- # These are explicitly windows files and should use crlf
53
- *.bat text eol=crlf
54
- *.cmd text eol=crlf
55
- *.ps1 text eol=crlf
56
-
57
- # Serialisation
58
- *.json text
59
- *.toml text
60
- *.xml text
61
- *.yaml text
62
- *.yml text
63
-
64
- # Archives
65
- *.7z binary
66
- *.gz binary
67
- *.tar binary
68
- *.tgz binary
69
- *.zip binary
70
-
71
- # Text files where line endings should be preserved
72
- *.patch -text
73
-
74
- #
75
- # Exclude files from exporting
76
- #
77
-
78
- .gitattributes export-ignore
79
- .gitignore export-ignore
80
-
81
- # Java sources
82
- *.java text diff=java
83
- *.gradle text diff=java
84
- *.gradle.kts text diff=java
85
-
86
- # These files are text and should be normalized (Convert crlf => lf)
87
- *.css text diff=css
88
- *.df text
89
- *.htm text diff=html
90
- *.html text diff=html
91
- *.js text
92
- *.jsp text
93
- *.jspf text
94
- *.jspx text
95
- *.properties text
96
- *.tld text
97
- *.tag text
98
- *.tagx text
99
- *.xml text
100
-
101
- # These files shouldn't be taken into account for statistics
102
- # since they are from external libraries
103
-
104
-
105
- # These files are binary and should be left untouched
106
- # (binary is a macro for -text -diff)
107
- *.class binary
108
- *.dll binary
109
- *.ear binary
110
- *.jar binary
111
- *.so binary
112
- *.war binary
@@ -1,61 +0,0 @@
1
- <component name="ProjectCodeStyleConfiguration">
2
- <code_scheme name="Project" version="173">
3
- <HTMLCodeStyleSettings>
4
- <option name="HTML_SPACE_INSIDE_EMPTY_TAG" value="true" />
5
- <option name="HTML_QUOTE_STYLE" value="Single" />
6
- <option name="HTML_ENFORCE_QUOTES" value="true" />
7
- </HTMLCodeStyleSettings>
8
- <JSCodeStyleSettings version="0">
9
- <option name="FORCE_SEMICOLON_STYLE" value="true" />
10
- <option name="SPACE_BEFORE_FUNCTION_LEFT_PARENTH" value="false" />
11
- <option name="USE_DOUBLE_QUOTES" value="false" />
12
- <option name="FORCE_QUOTE_STYlE" value="true" />
13
- <option name="ENFORCE_TRAILING_COMMA" value="Remove" />
14
- <option name="SPACES_WITHIN_OBJECT_TYPE_BRACES" value="false" />
15
- </JSCodeStyleSettings>
16
- <TypeScriptCodeStyleSettings version="0">
17
- <option name="FORCE_SEMICOLON_STYLE" value="true" />
18
- <option name="SPACE_BEFORE_FUNCTION_LEFT_PARENTH" value="false" />
19
- <option name="USE_DOUBLE_QUOTES" value="false" />
20
- <option name="FORCE_QUOTE_STYlE" value="true" />
21
- <option name="ENFORCE_TRAILING_COMMA" value="Remove" />
22
- <option name="SPACES_WITHIN_OBJECT_TYPE_BRACES" value="false" />
23
- </TypeScriptCodeStyleSettings>
24
- <VueCodeStyleSettings>
25
- <option name="INTERPOLATION_NEW_LINE_AFTER_START_DELIMITER" value="false" />
26
- <option name="INTERPOLATION_NEW_LINE_BEFORE_END_DELIMITER" value="false" />
27
- </VueCodeStyleSettings>
28
- <codeStyleSettings language="HTML">
29
- <option name="SOFT_MARGINS" value="120" />
30
- <indentOptions>
31
- <option name="INDENT_SIZE" value="2" />
32
- <option name="CONTINUATION_INDENT_SIZE" value="2" />
33
- <option name="TAB_SIZE" value="2" />
34
- </indentOptions>
35
- </codeStyleSettings>
36
- <codeStyleSettings language="JavaScript">
37
- <option name="RIGHT_MARGIN" value="120" />
38
- <option name="SOFT_MARGINS" value="120" />
39
- <indentOptions>
40
- <option name="INDENT_SIZE" value="2" />
41
- <option name="CONTINUATION_INDENT_SIZE" value="2" />
42
- <option name="TAB_SIZE" value="2" />
43
- </indentOptions>
44
- </codeStyleSettings>
45
- <codeStyleSettings language="TypeScript">
46
- <option name="RIGHT_MARGIN" value="120" />
47
- <option name="SOFT_MARGINS" value="120" />
48
- <indentOptions>
49
- <option name="INDENT_SIZE" value="2" />
50
- <option name="CONTINUATION_INDENT_SIZE" value="2" />
51
- <option name="TAB_SIZE" value="2" />
52
- </indentOptions>
53
- </codeStyleSettings>
54
- <codeStyleSettings language="Vue">
55
- <option name="SOFT_MARGINS" value="120" />
56
- <indentOptions>
57
- <option name="CONTINUATION_INDENT_SIZE" value="2" />
58
- </indentOptions>
59
- </codeStyleSettings>
60
- </code_scheme>
61
- </component>
@@ -1,5 +0,0 @@
1
- <component name="ProjectCodeStyleConfiguration">
2
- <state>
3
- <option name="USE_PER_PROJECT_SETTINGS" value="true" />
4
- </state>
5
- </component>
@@ -1,19 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <module type="WEB_MODULE" version="4">
3
- <component name="NewModuleRootManager">
4
- <content url="file://$MODULE_DIR$">
5
- <excludeFolder url="file://$MODULE_DIR$/temp" />
6
- <excludeFolder url="file://$MODULE_DIR$/.tmp" />
7
- <excludeFolder url="file://$MODULE_DIR$/tmp" />
8
- <excludeFolder url="file://$MODULE_DIR$/docs" />
9
- <excludeFolder url="file://$MODULE_DIR$/backup" />
10
- <excludeFolder url="file://$MODULE_DIR$/lib" />
11
- <excludeFolder url="file://$MODULE_DIR$/notes" />
12
- <excludeFolder url="file://$MODULE_DIR$/umd" />
13
- <excludeFolder url="file://$MODULE_DIR$/coverage" />
14
- <excludeFolder url="file://$MODULE_DIR$/.vscode" />
15
- </content>
16
- <orderEntry type="inheritedJdk" />
17
- <orderEntry type="sourceFolder" forTests="false" />
18
- </component>
19
- </module>
@@ -1,6 +0,0 @@
1
- <component name="InspectionProjectProfileManager">
2
- <profile version="1.0">
3
- <option name="myName" value="Project Default" />
4
- <inspection_tool class="Eslint" enabled="true" level="WARNING" enabled_by_default="true" />
5
- </profile>
6
- </component>
package/.idea/misc.xml DELETED
@@ -1,6 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="WebPackConfiguration">
4
- <option name="mode" value="DISABLED" />
5
- </component>
6
- </project>
package/.idea/modules.xml DELETED
@@ -1,8 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="ProjectModuleManager">
4
- <modules>
5
- <module fileurl="file://$PROJECT_DIR$/.idea/data-structure-typed.iml" filepath="$PROJECT_DIR$/.idea/data-structure-typed.iml" />
6
- </modules>
7
- </component>
8
- </project>
package/.idea/vcs.xml DELETED
@@ -1,6 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="VcsDirectoryMappings">
4
- <mapping directory="$PROJECT_DIR$" vcs="Git" />
5
- </component>
6
- </project>
package/.prettierignore DELETED
@@ -1,6 +0,0 @@
1
- src/types/data-structures/abstract-binary-tree.ts
2
- src/types/data-structures/binary-tree.ts
3
- src/types/data-structures/bst.ts
4
- src/types/data-structures/avl-tree.ts
5
- src/types/data-structures/tree-multiset.ts
6
- src/types/data-structures/rb-tree.ts
package/webpack.config.js DELETED
@@ -1,28 +0,0 @@
1
- const path = require('path');
2
-
3
- module.exports = [
4
- {
5
- mode:'production',
6
- entry: './src/index.ts',
7
- target: 'web',
8
- output: {
9
- filename: 'bundle.min.js',
10
- path: path.resolve(__dirname, 'umd'),
11
- library: 'dataStructureTyped',
12
- libraryTarget: 'umd',
13
- },
14
- resolve: {
15
- extensions: ['.ts', '.js'],
16
- },
17
- module: {
18
- rules: [
19
- {
20
- test: /\.ts$/,
21
- use: 'ts-loader',
22
- exclude: /node_modules/,
23
- }
24
- ],
25
- },
26
- devtool: 'source-map',
27
- },
28
- ];