@squiz/dx-common-lib 1.2.11 → 1.2.13-alpha.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 (109) hide show
  1. package/CHANGELOG.md +8 -66
  2. package/lib/api-key-validation/ApiKeyValidationService.d.ts +4 -0
  3. package/lib/api-key-validation/ApiKeyValidationService.js +3 -0
  4. package/lib/api-key-validation/ApiKeyValidationService.js.map +1 -0
  5. package/lib/api-key-validation/CloudflareApiKeyService.d.ts +17 -0
  6. package/lib/api-key-validation/CloudflareApiKeyService.js +72 -0
  7. package/lib/api-key-validation/CloudflareApiKeyService.js.map +1 -0
  8. package/lib/api-key-validation/CloudflareApiKeyService.spec.d.ts +1 -0
  9. package/lib/api-key-validation/CloudflareApiKeyService.spec.js +93 -0
  10. package/lib/api-key-validation/CloudflareApiKeyService.spec.js.map +1 -0
  11. package/lib/api-key-validation/DevelopmentApiKeyService.d.ts +5 -0
  12. package/lib/api-key-validation/DevelopmentApiKeyService.js +13 -0
  13. package/lib/api-key-validation/DevelopmentApiKeyService.js.map +1 -0
  14. package/lib/api-key-validation/DevelopmentApiKeyService.spec.d.ts +1 -0
  15. package/lib/api-key-validation/DevelopmentApiKeyService.spec.js +17 -0
  16. package/lib/api-key-validation/DevelopmentApiKeyService.spec.js.map +1 -0
  17. package/lib/api-key-validation/getApiKeyService.d.ts +6 -0
  18. package/lib/api-key-validation/getApiKeyService.js +23 -0
  19. package/lib/api-key-validation/getApiKeyService.js.map +1 -0
  20. package/lib/api-key-validation/getApiKeyService.spec.d.ts +1 -0
  21. package/lib/api-key-validation/getApiKeyService.spec.js +24 -0
  22. package/lib/api-key-validation/getApiKeyService.spec.js.map +1 -0
  23. package/lib/assertions/assertAssignWithDefaultUndefinedValue.d.ts +0 -1
  24. package/lib/assertions/assertAssignWithDefaultUndefinedValue.js +1 -3
  25. package/lib/assertions/assertAssignWithDefaultUndefinedValue.js.map +1 -1
  26. package/lib/cache/applyDefaultRulesToCacheControlObject.d.ts +19 -0
  27. package/lib/cache/applyDefaultRulesToCacheControlObject.js +21 -0
  28. package/lib/cache/applyDefaultRulesToCacheControlObject.js.map +1 -0
  29. package/lib/cache/applyDefaultRulesToCacheControlObject.spec.d.ts +1 -0
  30. package/lib/cache/applyDefaultRulesToCacheControlObject.spec.js +97 -0
  31. package/lib/cache/applyDefaultRulesToCacheControlObject.spec.js.map +1 -0
  32. package/lib/cache/cacheControlToString.d.ts +2 -0
  33. package/lib/cache/cacheControlToString.js +24 -0
  34. package/lib/cache/cacheControlToString.js.map +1 -0
  35. package/lib/cache/cacheControlToString.spec.d.ts +1 -0
  36. package/lib/cache/cacheControlToString.spec.js +34 -0
  37. package/lib/cache/cacheControlToString.spec.js.map +1 -0
  38. package/lib/cache/index.d.ts +4 -0
  39. package/lib/cache/index.js +21 -0
  40. package/lib/cache/index.js.map +1 -0
  41. package/lib/cache/parseAndSanitiseCacheControlHeader.d.ts +5 -0
  42. package/lib/cache/parseAndSanitiseCacheControlHeader.js +26 -0
  43. package/lib/cache/parseAndSanitiseCacheControlHeader.js.map +1 -0
  44. package/lib/cache/parseAndSanitiseCacheControlHeader.spec.d.ts +1 -0
  45. package/lib/cache/parseAndSanitiseCacheControlHeader.spec.js +21 -0
  46. package/lib/cache/parseAndSanitiseCacheControlHeader.spec.js.map +1 -0
  47. package/lib/cache/parseCacheControl.d.ts +19 -0
  48. package/lib/cache/parseCacheControl.js +46 -0
  49. package/lib/cache/parseCacheControl.js.map +1 -0
  50. package/lib/cache/parseCacheControl.spec.d.ts +1 -0
  51. package/lib/cache/parseCacheControl.spec.js +70 -0
  52. package/lib/cache/parseCacheControl.spec.js.map +1 -0
  53. package/lib/error/InvalidTokenError.d.ts +5 -0
  54. package/lib/error/InvalidTokenError.js +12 -0
  55. package/lib/error/InvalidTokenError.js.map +1 -0
  56. package/lib/error/UnAuthenticatedRequestError.d.ts +4 -0
  57. package/lib/error/UnAuthenticatedRequestError.js +11 -0
  58. package/lib/error/UnAuthenticatedRequestError.js.map +1 -0
  59. package/lib/error/UnprivilegedError.d.ts +5 -0
  60. package/lib/error/UnprivilegedError.js +12 -0
  61. package/lib/error/UnprivilegedError.js.map +1 -0
  62. package/lib/error/index.d.ts +3 -0
  63. package/lib/error/index.js +3 -0
  64. package/lib/error/index.js.map +1 -1
  65. package/lib/formatted-text/formattedTextToHtmlSting.d.ts +4 -0
  66. package/lib/formatted-text/formattedTextToHtmlSting.js +85 -0
  67. package/lib/formatted-text/formattedTextToHtmlSting.js.map +1 -0
  68. package/lib/formatted-text/formattedTextToHtmlSting.spec.d.ts +1 -0
  69. package/lib/formatted-text/formattedTextToHtmlSting.spec.js +212 -0
  70. package/lib/formatted-text/formattedTextToHtmlSting.spec.js.map +1 -0
  71. package/lib/index.d.ts +7 -0
  72. package/lib/index.js +7 -0
  73. package/lib/index.js.map +1 -1
  74. package/lib/server-utils/apiKeyMiddleware.d.ts +3 -0
  75. package/lib/server-utils/apiKeyMiddleware.js +20 -0
  76. package/lib/server-utils/apiKeyMiddleware.js.map +1 -0
  77. package/lib/server-utils/apiKeyMiddleware.spec.d.ts +1 -0
  78. package/lib/server-utils/apiKeyMiddleware.spec.js +39 -0
  79. package/lib/server-utils/apiKeyMiddleware.spec.js.map +1 -0
  80. package/lib/util/getPageInfo.d.ts +2 -2
  81. package/package.json +10 -8
  82. package/src/api-key-validation/ApiKeyValidationService.ts +4 -0
  83. package/src/api-key-validation/CloudflareApiKeyService.spec.ts +122 -0
  84. package/src/api-key-validation/CloudflareApiKeyService.ts +96 -0
  85. package/src/api-key-validation/DevelopmentApiKeyService.spec.ts +17 -0
  86. package/src/api-key-validation/DevelopmentApiKeyService.ts +10 -0
  87. package/src/api-key-validation/getApiKeyService.spec.ts +32 -0
  88. package/src/api-key-validation/getApiKeyService.ts +27 -0
  89. package/src/assertions/assertAssignWithDefaultUndefinedValue.ts +0 -5
  90. package/src/cache/applyDefaultRulesToCacheControlObject.spec.ts +126 -0
  91. package/src/cache/applyDefaultRulesToCacheControlObject.ts +23 -0
  92. package/src/cache/cacheControlToString.spec.ts +43 -0
  93. package/src/cache/cacheControlToString.ts +22 -0
  94. package/src/cache/index.ts +4 -0
  95. package/src/cache/parseAndSanitiseCacheControlHeader.spec.ts +25 -0
  96. package/src/cache/parseAndSanitiseCacheControlHeader.ts +28 -0
  97. package/src/cache/parseCacheControl.spec.ts +89 -0
  98. package/src/cache/parseCacheControl.ts +74 -0
  99. package/src/error/InvalidTokenError.ts +8 -0
  100. package/src/error/UnAuthenticatedRequestError.ts +7 -0
  101. package/src/error/UnprivilegedError.ts +8 -0
  102. package/src/error/index.ts +4 -0
  103. package/src/formatted-text/formattedTextToHtmlSting.spec.ts +235 -0
  104. package/src/formatted-text/formattedTextToHtmlSting.ts +100 -0
  105. package/src/index.ts +7 -0
  106. package/src/server-utils/apiKeyMiddleware.spec.ts +50 -0
  107. package/src/server-utils/apiKeyMiddleware.ts +23 -0
  108. package/tsconfig.json +1 -1
  109. package/tsconfig.tsbuildinfo +1 -1
@@ -0,0 +1,235 @@
1
+ import { FORMATTED_TEXT_MODELS } from '@squiz/dx-json-schema-lib';
2
+ import { formattedTextToHtmlSting } from './formattedTextToHtmlSting';
3
+
4
+ type FormattedNodes = FORMATTED_TEXT_MODELS.v1.FormattedNodes;
5
+ type FormattedTextTag = FORMATTED_TEXT_MODELS.v1.FormattedTextTag;
6
+
7
+ describe('formattedTextToHtmlSting', () => {
8
+ it('should convert text nodes to HTML', () => {
9
+ const textNode: FormattedNodes = {
10
+ type: 'text',
11
+ value: 'Hello, world!',
12
+ };
13
+ expect(formattedTextToHtmlSting(textNode)).toBe('Hello, world!');
14
+ });
15
+
16
+ it('should convert tag nodes to HTML', () => {
17
+ const tagNode: FormattedNodes = {
18
+ type: 'tag',
19
+ tag: 'p',
20
+ children: [{ type: 'text', value: 'Hello, world!' }],
21
+ };
22
+ expect(formattedTextToHtmlSting(tagNode)).toBe('<p>Hello, world!</p>');
23
+ });
24
+
25
+ it('should convert tag nodes with attributes to HTML', () => {
26
+ const tagNode: FormattedNodes = {
27
+ type: 'tag',
28
+ tag: 'p',
29
+ attributes: {
30
+ id: 'hello-world',
31
+ class: 'greeting',
32
+ },
33
+ children: [{ type: 'text', value: 'Hello, world!' }],
34
+ };
35
+ expect(formattedTextToHtmlSting(tagNode)).toBe('<p id="hello-world" class="greeting">Hello, world!</p>');
36
+ });
37
+
38
+ it('should convert tag nodes with font properties to HTML', () => {
39
+ const tagNode: FormattedNodes = {
40
+ type: 'tag',
41
+ tag: 'p',
42
+ font: {
43
+ bold: true,
44
+ underline: true,
45
+ italics: false,
46
+ color: 'red',
47
+ size: 'large',
48
+ fontFamily: 'Arial',
49
+ },
50
+ children: [{ type: 'text', value: 'Hello, world!' }],
51
+ };
52
+ expect(formattedTextToHtmlSting(tagNode)).toBe(
53
+ '<p class="bold underline color-red size-large font-Arial">Hello, world!</p>',
54
+ );
55
+ });
56
+
57
+ it('converts a tag node with attributes but no children to html', () => {
58
+ const node: FormattedNodes = {
59
+ type: 'tag',
60
+ tag: 'p',
61
+ children: [],
62
+ attributes: { class: 'test-class' },
63
+ };
64
+ expect(formattedTextToHtmlSting(node)).toEqual('<p class="test-class"></p>');
65
+ });
66
+
67
+ it('converts a tag node with children but no attributes to html', () => {
68
+ const node: FormattedNodes = {
69
+ type: 'tag',
70
+ tag: 'p',
71
+ children: [
72
+ { type: 'text', value: 'This is a test' },
73
+ { type: 'text', value: 'This is another test' },
74
+ ],
75
+ };
76
+ expect(formattedTextToHtmlSting(node)).toEqual('<p>This is a testThis is another test</p>');
77
+ });
78
+
79
+ it('converts a tag node with children and attributes to html', () => {
80
+ const node: FormattedNodes = {
81
+ type: 'tag',
82
+ tag: 'p',
83
+ attributes: { class: 'test-class' },
84
+ children: [
85
+ { type: 'text', value: 'This is a test' },
86
+ { type: 'text', value: 'This is another test' },
87
+ ],
88
+ };
89
+ expect(formattedTextToHtmlSting(node)).toEqual('<p class="test-class">This is a testThis is another test</p>');
90
+ });
91
+
92
+ it('should convert a tag node with attributes to HTML', () => {
93
+ const input: FormattedNodes = {
94
+ type: 'tag',
95
+ tag: 'div',
96
+ children: [],
97
+ attributes: {
98
+ id: 'my-div',
99
+ 'data-foo': 'bar',
100
+ },
101
+ };
102
+ const expectedOutput = '<div id="my-div" data-foo="bar"></div>';
103
+ expect(formattedTextToHtmlSting(input)).toEqual(expectedOutput);
104
+ });
105
+
106
+ it('should add the correct class for left alignment', () => {
107
+ const formattedNode: FormattedTextTag = {
108
+ type: 'tag',
109
+ children: [],
110
+ tag: 'p',
111
+ formattingOptions: {
112
+ alignment: 'left',
113
+ },
114
+ };
115
+ const html = formattedTextToHtmlSting(formattedNode);
116
+ expect(html).toEqual('<p class="left"></p>');
117
+ });
118
+
119
+ it('should add the correct class for right alignment', () => {
120
+ const formattedNode: FormattedTextTag = {
121
+ type: 'tag',
122
+ children: [],
123
+ tag: 'p',
124
+ formattingOptions: {
125
+ alignment: 'right',
126
+ },
127
+ };
128
+ const html = formattedTextToHtmlSting(formattedNode);
129
+ expect(html).toEqual('<p class="right"></p>');
130
+ });
131
+
132
+ it('should add the correct class for center alignment', () => {
133
+ const formattedNode: FormattedTextTag = {
134
+ type: 'tag',
135
+ children: [],
136
+ tag: 'p',
137
+ formattingOptions: {
138
+ alignment: 'center',
139
+ },
140
+ };
141
+ const html = formattedTextToHtmlSting(formattedNode);
142
+ expect(html).toEqual('<p class="center"></p>');
143
+ });
144
+
145
+ it('should add the correct class for justify alignment', () => {
146
+ const formattedNode: FormattedTextTag = {
147
+ type: 'tag',
148
+ children: [],
149
+ tag: 'p',
150
+ formattingOptions: {
151
+ alignment: 'justify',
152
+ },
153
+ };
154
+ const html = formattedTextToHtmlSting(formattedNode);
155
+ expect(html).toEqual('<p class="justify"></p>');
156
+ });
157
+
158
+ it('should handle input with formattingOptions, font and class attributes', () => {
159
+ const formattedTextTag: FormattedTextTag = {
160
+ type: 'tag',
161
+ tag: 'p',
162
+ formattingOptions: {
163
+ alignment: 'center',
164
+ },
165
+ font: {
166
+ bold: true,
167
+ color: 'red',
168
+ },
169
+ attributes: {
170
+ class: 'my-class',
171
+ },
172
+ children: [
173
+ {
174
+ type: 'text',
175
+ value: 'Hello, World!',
176
+ },
177
+ ],
178
+ };
179
+
180
+ const expectedResult = '<p class="my-class bold color-red center">Hello, World!</p>';
181
+
182
+ const result = formattedTextToHtmlSting(formattedTextTag);
183
+ expect(result).toBe(expectedResult);
184
+ });
185
+
186
+ it('should return an error message for an unknown node type', () => {
187
+ const formattedNodes: FormattedNodes = {
188
+ type: 'unknown' as any,
189
+ value: 'Hello World!',
190
+ };
191
+ const expectedHTML = `<p class="invalid-node-type"> node of type "unknown" cannot be converted to html</p>`;
192
+ expect(formattedTextToHtmlSting(formattedNodes)).toEqual(expectedHTML);
193
+ });
194
+
195
+ it('should handle deeply nested FormattedNodes object', () => {
196
+ const formattedNodes: FormattedNodes = {
197
+ type: 'tag',
198
+ tag: 'div',
199
+ formattingOptions: {
200
+ alignment: 'justify',
201
+ },
202
+ children: [
203
+ {
204
+ type: 'text',
205
+ value: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. ',
206
+ },
207
+ {
208
+ type: 'tag',
209
+ tag: 'strong',
210
+ font: {
211
+ bold: true,
212
+ },
213
+ children: [
214
+ {
215
+ type: 'text',
216
+ value: 'Vestibulum',
217
+ },
218
+ {
219
+ type: 'text',
220
+ value: ' dictum',
221
+ },
222
+ ],
223
+ },
224
+ {
225
+ type: 'text',
226
+ value: ' mi vel urna maximus, et luctus ipsum tincidunt',
227
+ },
228
+ ],
229
+ };
230
+
231
+ expect(formattedTextToHtmlSting(formattedNodes)).toMatchInlineSnapshot(
232
+ `"<div class=\\"justify\\">Lorem ipsum dolor sit amet, consectetur adipiscing elit. <strong class=\\"bold\\">Vestibulum dictum</strong> mi vel urna maximus, et luctus ipsum tincidunt</div>"`,
233
+ );
234
+ });
235
+ });
@@ -0,0 +1,100 @@
1
+ import { FORMATTED_TEXT_MODELS } from '@squiz/dx-json-schema-lib';
2
+
3
+ type FormattedNodes = FORMATTED_TEXT_MODELS.v1.FormattedNodes;
4
+ type FormattedTextTag = FORMATTED_TEXT_MODELS.v1.FormattedTextTag;
5
+ type FormattedNodeFontProperties = FORMATTED_TEXT_MODELS.v1.FormattedNodeFontProperties;
6
+
7
+ export function formattedTextToHtmlSting(formattedNodes: FormattedNodes): string {
8
+ switch (formattedNodes.type) {
9
+ case 'text':
10
+ return formattedNodes.value;
11
+ case 'tag':
12
+ return buildTagHTML(formattedNodes);
13
+ default:
14
+ return unknownNodeType(formattedNodes);
15
+ }
16
+ }
17
+ function buildTagHTML(formattedTextTag: FormattedTextTag): string {
18
+ const classes = getClassString(formattedTextTag);
19
+
20
+ if (!formattedTextTag.attributes) {
21
+ formattedTextTag.attributes = { class: classes };
22
+ } else {
23
+ formattedTextTag.attributes.class = classes;
24
+ }
25
+
26
+ const attributesStr = buildAttributesString(formattedTextTag.attributes);
27
+ const childrenHTML = buildChildrenHTML(formattedTextTag.children);
28
+
29
+ return `<${formattedTextTag.tag}${attributesStr}>${childrenHTML}</${formattedTextTag.tag}>`;
30
+ }
31
+
32
+ function buildChildrenHTML(children: FormattedNodes[] | undefined): string {
33
+ if (!children) {
34
+ return '';
35
+ }
36
+ return children.map(formattedTextToHtmlSting).join('');
37
+ }
38
+
39
+ function unknownNodeType(node: FormattedNodes): string {
40
+ return `<p class="invalid-node-type"> node of type "${node.type}" cannot be converted to html</p>`;
41
+ }
42
+
43
+ function getClassString(formattedTextTag: FormattedTextTag) {
44
+ const fontClasses = buildFontClasses(formattedTextTag.font);
45
+
46
+ let string = formattedTextTag?.attributes?.class ?? '';
47
+
48
+ if (formattedTextTag?.formattingOptions?.alignment) {
49
+ fontClasses.push(formattedTextTag.formattingOptions.alignment);
50
+ }
51
+
52
+ if (fontClasses.length > 0) {
53
+ string += ' ' + fontClasses.join(' ');
54
+ }
55
+
56
+ return string.trim();
57
+ }
58
+
59
+ function buildAttributesString(attributes: { [k: string]: string } | undefined): string {
60
+ if (!attributes) {
61
+ return '';
62
+ }
63
+
64
+ let attributesString = '';
65
+ for (const attribute in attributes) {
66
+ if (attributes[attribute] !== '') {
67
+ attributesString += ` ${attribute}="${attributes[attribute]}"`;
68
+ }
69
+ }
70
+
71
+ return attributesString;
72
+ }
73
+
74
+ function buildFontClasses(font: FormattedNodeFontProperties | undefined): string[] {
75
+ if (!font) {
76
+ return [];
77
+ }
78
+
79
+ const classes: string[] = [];
80
+ if (font.bold) {
81
+ classes.push('bold');
82
+ }
83
+ if (font.underline) {
84
+ classes.push('underline');
85
+ }
86
+ if (font.italics) {
87
+ classes.push('italics');
88
+ }
89
+ if (font.color) {
90
+ classes.push(`color-${font.color}`);
91
+ }
92
+ if (font.size) {
93
+ classes.push(`size-${font.size}`);
94
+ }
95
+ if (font.fontFamily) {
96
+ classes.push(`font-${font.fontFamily}`);
97
+ }
98
+
99
+ return classes;
100
+ }
package/src/index.ts CHANGED
@@ -4,3 +4,10 @@ export * from './util';
4
4
  export * from './zip/zipDirectory';
5
5
  export * from './server-utils/errorMiddleware';
6
6
  export * from './server-utils/requestLogger';
7
+ export * from './api-key-validation/ApiKeyValidationService';
8
+ export * from './api-key-validation/CloudflareApiKeyService';
9
+ export * from './api-key-validation/DevelopmentApiKeyService';
10
+ export * from './api-key-validation/getApiKeyService';
11
+ export * from './server-utils/apiKeyMiddleware';
12
+ export * from './cache';
13
+ export * from './formatted-text/formattedTextToHtmlSting';
@@ -0,0 +1,50 @@
1
+ import { UnAuthenticatedRequestError } from '../error/UnAuthenticatedRequestError';
2
+ import { apiKeyMiddleware } from './apiKeyMiddleware';
3
+
4
+ const keyIsValid = jest.fn().mockImplementation(() => true);
5
+ const matrixKeyIsValid = jest.fn().mockImplementation(() => true);
6
+
7
+ describe('apiKeyMiddleware', () => {
8
+ const middleware = apiKeyMiddleware({ keyIsValid, matrixKeyIsValid });
9
+
10
+ it('should return an express middleware which', () => {
11
+ expect(middleware).toBeInstanceOf(Function);
12
+ });
13
+
14
+ describe('middleware', () => {
15
+ it('should call next is key is invalid but matrix ke is valid', () => {
16
+ const nextFunc = jest.fn().mockImplementation(() => {
17
+ /* no op */
18
+ });
19
+ keyIsValid.mockImplementation(() => false);
20
+ keyIsValid.mockImplementation(() => true);
21
+
22
+ middleware({ header: () => 'some-key' } as any, {} as any, nextFunc);
23
+
24
+ expect(nextFunc).toHaveBeenCalled();
25
+ });
26
+
27
+ it('should call next if api key is valid', () => {
28
+ const nextFunc = jest.fn().mockImplementation(() => {
29
+ /* no op */
30
+ });
31
+
32
+ middleware({ header: () => 'some-key' } as any, {} as any, nextFunc);
33
+
34
+ expect(nextFunc).toHaveBeenCalled();
35
+ });
36
+
37
+ it('should throw an UnAuthenticatedRequestError if key is invalid', () => {
38
+ const nextFunc = jest.fn().mockImplementation(() => {
39
+ /* no op */
40
+ });
41
+
42
+ keyIsValid.mockImplementation(() => false);
43
+ matrixKeyIsValid.mockImplementation(() => false);
44
+
45
+ expect(() => middleware({ header: () => 'some-key' } as any, {} as any, nextFunc)).toThrowError(
46
+ new UnAuthenticatedRequestError(`API KEY IS INVALID`),
47
+ );
48
+ });
49
+ });
50
+ });
@@ -0,0 +1,23 @@
1
+ import type { Request, Response } from 'express';
2
+ import { ApiKeyValidationService } from '../api-key-validation/ApiKeyValidationService';
3
+ import { UnAuthenticatedRequestError } from '../error/UnAuthenticatedRequestError';
4
+
5
+ export function apiKeyMiddleware(
6
+ apiKeyService: ApiKeyValidationService,
7
+ ): (req: Request, res: Response, next: any) => void {
8
+ return function (req: Request, res: Response, next: any) {
9
+ const key = req.header('x-api-key');
10
+
11
+ if (req.path == '/health') {
12
+ next();
13
+ return;
14
+ }
15
+
16
+ if (apiKeyService.keyIsValid(key) || apiKeyService.matrixKeyIsValid(key)) {
17
+ next();
18
+ return;
19
+ }
20
+
21
+ throw new UnAuthenticatedRequestError(`API KEY IS INVALID`);
22
+ };
23
+ }
package/tsconfig.json CHANGED
@@ -9,7 +9,7 @@
9
9
  "sourceMap": true
10
10
  },
11
11
 
12
- "references": [],
12
+ "references": [{ "path": "../dx-json-schema-lib" }],
13
13
 
14
14
  "include": ["src/**/*.ts", "src/**/*.json"],
15
15
  "exclude": ["jest.config.ts"]