@payloadcms/plugin-cloud-storage 1.1.0-beta.1 → 1.1.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 (135) hide show
  1. package/package.json +3 -4
  2. package/.editorconfig +0 -10
  3. package/.gitignore +0 -248
  4. package/.prettierignore +0 -1
  5. package/.vscode/settings.json +0 -9
  6. package/dev/.env +0 -21
  7. package/dev/.env.example +0 -21
  8. package/dev/dist/dev/src/collections/Media.js +0 -56
  9. package/dev/dist/dev/src/collections/Media.js.map +0 -1
  10. package/dev/dist/dev/src/collections/Users.js +0 -23
  11. package/dev/dist/dev/src/collections/Users.js.map +0 -1
  12. package/dev/dist/dev/src/payload.config.js +0 -153
  13. package/dev/dist/dev/src/payload.config.js.map +0 -1
  14. package/dev/dist/dev/src/server.js +0 -26
  15. package/dev/dist/dev/src/server.js.map +0 -1
  16. package/dev/dist/src/adapters/azure/generateURL.js +0 -16
  17. package/dev/dist/src/adapters/azure/generateURL.js.map +0 -1
  18. package/dev/dist/src/adapters/azure/handleDelete.js +0 -64
  19. package/dev/dist/src/adapters/azure/handleDelete.js.map +0 -1
  20. package/dev/dist/src/adapters/azure/handleUpload.js +0 -81
  21. package/dev/dist/src/adapters/azure/handleUpload.js.map +0 -1
  22. package/dev/dist/src/adapters/azure/index.js +0 -43
  23. package/dev/dist/src/adapters/azure/index.js.map +0 -1
  24. package/dev/dist/src/adapters/azure/staticHandler.js +0 -82
  25. package/dev/dist/src/adapters/azure/staticHandler.js.map +0 -1
  26. package/dev/dist/src/adapters/azure/webpack.js +0 -25
  27. package/dev/dist/src/adapters/azure/webpack.js.map +0 -1
  28. package/dev/dist/src/adapters/gcs/generateURL.js +0 -16
  29. package/dev/dist/src/adapters/gcs/generateURL.js.map +0 -1
  30. package/dev/dist/src/adapters/gcs/handleDelete.js +0 -63
  31. package/dev/dist/src/adapters/gcs/handleDelete.js.map +0 -1
  32. package/dev/dist/src/adapters/gcs/handleUpload.js +0 -73
  33. package/dev/dist/src/adapters/gcs/handleUpload.js.map +0 -1
  34. package/dev/dist/src/adapters/gcs/index.js +0 -36
  35. package/dev/dist/src/adapters/gcs/index.js.map +0 -1
  36. package/dev/dist/src/adapters/gcs/staticHandler.js +0 -77
  37. package/dev/dist/src/adapters/gcs/staticHandler.js.map +0 -1
  38. package/dev/dist/src/adapters/gcs/webpack.js +0 -25
  39. package/dev/dist/src/adapters/gcs/webpack.js.map +0 -1
  40. package/dev/dist/src/adapters/s3/generateURL.js +0 -16
  41. package/dev/dist/src/adapters/s3/generateURL.js.map +0 -1
  42. package/dev/dist/src/adapters/s3/handleDelete.js +0 -64
  43. package/dev/dist/src/adapters/s3/handleDelete.js.map +0 -1
  44. package/dev/dist/src/adapters/s3/handleUpload.js +0 -94
  45. package/dev/dist/src/adapters/s3/handleUpload.js.map +0 -1
  46. package/dev/dist/src/adapters/s3/index.js +0 -60
  47. package/dev/dist/src/adapters/s3/index.js.map +0 -1
  48. package/dev/dist/src/adapters/s3/staticHandler.js +0 -82
  49. package/dev/dist/src/adapters/s3/staticHandler.js.map +0 -1
  50. package/dev/dist/src/adapters/s3/webpack.js +0 -25
  51. package/dev/dist/src/adapters/s3/webpack.js.map +0 -1
  52. package/dev/dist/src/fields/getFields.js +0 -119
  53. package/dev/dist/src/fields/getFields.js.map +0 -1
  54. package/dev/dist/src/hooks/afterDelete.js +0 -92
  55. package/dev/dist/src/hooks/afterDelete.js.map +0 -1
  56. package/dev/dist/src/hooks/afterRead.js +0 -80
  57. package/dev/dist/src/hooks/afterRead.js.map +0 -1
  58. package/dev/dist/src/hooks/beforeChange.js +0 -106
  59. package/dev/dist/src/hooks/beforeChange.js.map +0 -1
  60. package/dev/dist/src/index.js +0 -6
  61. package/dev/dist/src/index.js.map +0 -1
  62. package/dev/dist/src/plugin.js +0 -131
  63. package/dev/dist/src/plugin.js.map +0 -1
  64. package/dev/dist/src/types.js +0 -3
  65. package/dev/dist/src/types.js.map +0 -1
  66. package/dev/dist/src/utilities/getFilePrefix.js +0 -81
  67. package/dev/dist/src/utilities/getFilePrefix.js.map +0 -1
  68. package/dev/dist/src/utilities/getIncomingFiles.js +0 -38
  69. package/dev/dist/src/utilities/getIncomingFiles.js.map +0 -1
  70. package/dev/dist/src/utilities/getRangeFromHeader.js +0 -67
  71. package/dev/dist/src/utilities/getRangeFromHeader.js.map +0 -1
  72. package/dev/dist/src/webpack.js +0 -40
  73. package/dev/dist/src/webpack.js.map +0 -1
  74. package/dev/nodemon.json +0 -8
  75. package/dev/package.json +0 -34
  76. package/dev/src/collections/Media.ts +0 -56
  77. package/dev/src/collections/Users.ts +0 -23
  78. package/dev/src/mocks/fsMock.js +0 -1
  79. package/dev/src/mocks/promisifyMock.js +0 -1
  80. package/dev/src/payload.config.ts +0 -123
  81. package/dev/src/server.ts +0 -26
  82. package/dev/tmp/tmp-1-1688568985997 +0 -0
  83. package/dev/tmp/tmp-2-1687546883112 +0 -0
  84. package/dev/tsconfig.json +0 -20
  85. package/docs/local-dev.md +0 -47
  86. package/eslint-config/index.js +0 -15
  87. package/eslint-config/rules/import.js +0 -38
  88. package/eslint-config/rules/prettier.js +0 -7
  89. package/eslint-config/rules/style.js +0 -21
  90. package/eslint-config/rules/typescript.js +0 -628
  91. package/src/adapters/azure/emulator/docker-compose.yml +0 -16
  92. package/src/adapters/azure/generateURL.ts +0 -13
  93. package/src/adapters/azure/handleDelete.ts +0 -16
  94. package/src/adapters/azure/handleUpload.ts +0 -43
  95. package/src/adapters/azure/index.ts +0 -48
  96. package/src/adapters/azure/mock.js +0 -1
  97. package/src/adapters/azure/staticHandler.ts +0 -38
  98. package/src/adapters/azure/webpack.ts +0 -21
  99. package/src/adapters/gcs/emulator/docker-compose.yml +0 -15
  100. package/src/adapters/gcs/generateURL.ts +0 -16
  101. package/src/adapters/gcs/handleDelete.ts +0 -16
  102. package/src/adapters/gcs/handleUpload.ts +0 -36
  103. package/src/adapters/gcs/index.ts +0 -40
  104. package/src/adapters/gcs/mock.js +0 -1
  105. package/src/adapters/gcs/staticHandler.ts +0 -34
  106. package/src/adapters/gcs/webpack.ts +0 -21
  107. package/src/adapters/s3/emulator/.localstack/cache/machine.json +0 -1
  108. package/src/adapters/s3/emulator/.localstack/cache/server.test.pem +0 -127
  109. package/src/adapters/s3/emulator/.localstack/cache/server.test.pem.crt +0 -99
  110. package/src/adapters/s3/emulator/.localstack/cache/server.test.pem.key +0 -28
  111. package/src/adapters/s3/emulator/.localstack/cache/service-catalog-2_1_1_dev-1_29_149.pickle +0 -0
  112. package/src/adapters/s3/emulator/docker-compose.yml +0 -15
  113. package/src/adapters/s3/generateURL.ts +0 -14
  114. package/src/adapters/s3/handleDelete.ts +0 -17
  115. package/src/adapters/s3/handleUpload.ts +0 -62
  116. package/src/adapters/s3/index.ts +0 -48
  117. package/src/adapters/s3/mock.js +0 -1
  118. package/src/adapters/s3/staticHandler.ts +0 -41
  119. package/src/adapters/s3/webpack.ts +0 -21
  120. package/src/admin/fields/getFields.ts +0 -126
  121. package/src/admin/index.ts +0 -39
  122. package/src/fields/getFields.ts +0 -155
  123. package/src/hooks/afterDelete.ts +0 -35
  124. package/src/hooks/afterRead.ts +0 -38
  125. package/src/hooks/beforeChange.ts +0 -59
  126. package/src/index.ts +0 -1
  127. package/src/plugin.ts +0 -101
  128. package/src/types.ts +0 -79
  129. package/src/utilities/getFilePrefix.ts +0 -26
  130. package/src/utilities/getIncomingFiles.ts +0 -44
  131. package/src/utilities/getRangeFromHeader.ts +0 -27
  132. package/src/webpack.ts +0 -48
  133. package/tsconfig.json +0 -23
  134. package/yarn-error.log +0 -8163
  135. package/yarn.lock +0 -8062
@@ -1,628 +0,0 @@
1
- module.exports = {
2
- plugins: ['@typescript-eslint'],
3
- overrides: [
4
- {
5
- files: ['**/**.ts', '**/**.d.ts'],
6
- rules: {
7
- 'no-undef': 'off',
8
- camelcase: 'off',
9
- '@typescript-eslint/adjacent-overload-signatures': 'error',
10
- /**
11
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/array-type.md
12
- */
13
- '@typescript-eslint/array-type': ['error', { default: 'array-simple' }],
14
- /**
15
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/await-thenable.md
16
- */
17
- '@typescript-eslint/await-thenable': 'off',
18
- /**
19
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/consistent-type-assertions.md
20
- */
21
- '@typescript-eslint/consistent-type-assertions': [
22
- 'error',
23
- { assertionStyle: 'as', objectLiteralTypeAssertions: 'allow-as-parameter' },
24
- ],
25
- /**
26
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/consistent-type-definitions.md
27
- */
28
- '@typescript-eslint/consistent-type-definitions': ['error', 'interface'],
29
- /**
30
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/consistent-type-imports.md
31
- */
32
- '@typescript-eslint/consistent-type-imports': 'warn',
33
- /**
34
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/explicit-function-return-type.md
35
- */
36
- '@typescript-eslint/explicit-function-return-type': [
37
- 'error',
38
- {
39
- // TODO: come back and check if we need those
40
- allowExpressions: true,
41
- allowTypedFunctionExpressions: true,
42
- allowHigherOrderFunctions: true,
43
- allowConciseArrowFunctionExpressionsStartingWithVoid: false,
44
- },
45
- ],
46
- /**
47
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/explicit-member-accessibility.md
48
- */
49
- '@typescript-eslint/explicit-member-accessibility': [
50
- 'error',
51
- { accessibility: 'no-public' },
52
- ],
53
- /**
54
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/member-delimiter-style.md
55
- */
56
- '@typescript-eslint/member-delimiter-style': [
57
- 'error',
58
- {
59
- multiline: {
60
- delimiter: 'none',
61
- requireLast: true,
62
- },
63
- singleline: {
64
- delimiter: 'semi',
65
- requireLast: false,
66
- },
67
- },
68
- ],
69
- /**
70
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/method-signature-style.md
71
- */
72
- '@typescript-eslint/method-signature-style': 'off',
73
- /**
74
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/naming-convention.md
75
- */
76
- '@typescript-eslint/naming-convention': [
77
- 'off',
78
- {
79
- selector: 'default',
80
- format: ['camelCase'],
81
- leadingUnderscore: 'forbid',
82
- trailingUnderscore: 'forbid',
83
- },
84
- {
85
- selector: 'variable',
86
- format: ['camelCase', 'UPPER_CASE'],
87
- leadingUnderscore: 'forbid',
88
- trailingUnderscore: 'forbid',
89
- },
90
- // Enforce that type parameters (generics) are prefixed with T or U
91
- {
92
- selector: 'typeParameter',
93
- format: ['PascalCase'],
94
- prefix: ['T', 'U'],
95
- },
96
- // enforce boolean variables to start with proper prefix.
97
- {
98
- selector: 'variable',
99
- types: ['boolean'],
100
- format: ['PascalCase'],
101
- prefix: ['is', 'should', 'has', 'can', 'did', 'will'],
102
- },
103
- // Enforce that interface names do not begin with an I
104
- {
105
- selector: 'interface',
106
- format: ['PascalCase'],
107
- custom: {
108
- regex: '^I[A-Z]',
109
- match: false,
110
- },
111
- },
112
- {
113
- selector: [
114
- 'function',
115
- 'parameter',
116
- 'property',
117
- 'parameterProperty',
118
- 'method',
119
- 'accessor',
120
- ],
121
- format: ['camelCase'],
122
- leadingUnderscore: 'forbid',
123
- trailingUnderscore: 'forbid',
124
- },
125
- {
126
- selector: ['class', 'interface', 'typeAlias', 'enum', 'typeParameter'],
127
- format: ['PascalCase'],
128
- leadingUnderscore: 'forbid',
129
- trailingUnderscore: 'forbid',
130
- },
131
- ],
132
- /**
133
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-base-to-string.md
134
- */
135
- '@typescript-eslint/no-base-to-string': 'off',
136
- /**
137
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-confusing-non-null-assertion.md
138
- */
139
- '@typescript-eslint/no-confusing-non-null-assertion': 'error',
140
- /**
141
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-dynamic-delete.md
142
- */
143
- '@typescript-eslint/no-dynamic-delete': 'error',
144
- /**
145
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-empty-interface.md
146
- */
147
- '@typescript-eslint/no-empty-interface': 'off',
148
- /**
149
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-explicit-any.md
150
- */
151
- '@typescript-eslint/no-explicit-any': [
152
- 'warn',
153
- {
154
- ignoreRestArgs: true,
155
- // enable later
156
- fixToUnknown: false,
157
- },
158
- ],
159
- /**
160
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-extra-non-null-assertion.md
161
- */
162
- '@typescript-eslint/no-extra-non-null-assertion': 'error',
163
- /**
164
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-extraneous-class.md
165
- */
166
- '@typescript-eslint/no-extraneous-class': [
167
- 'error',
168
- {
169
- allowConstructorOnly: false,
170
- allowEmpty: false,
171
- allowStaticOnly: false,
172
- allowWithDecorator: false,
173
- },
174
- ],
175
- /**
176
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-floating-promises.md
177
- */
178
- '@typescript-eslint/no-floating-promises': 'off',
179
- /**
180
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-for-in-array.md
181
- */
182
- '@typescript-eslint/no-for-in-array': 'off',
183
- /**
184
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-implicit-any-catch.md
185
- */
186
- '@typescript-eslint/no-implicit-any-catch': [
187
- 'error',
188
- {
189
- allowExplicitAny: false,
190
- },
191
- ],
192
- /**
193
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-implied-eval.md
194
- */
195
- '@typescript-eslint/no-implied-eval': 'off',
196
- /**
197
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-inferrable-types.md
198
- */
199
- '@typescript-eslint/no-inferrable-types': [
200
- 'error',
201
- {
202
- ignoreParameters: false,
203
- ignoreProperties: false,
204
- },
205
- ],
206
- /**
207
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-invalid-void-type.md
208
- */
209
- '@typescript-eslint/no-invalid-void-type': [
210
- 'off',
211
- {
212
- allowInGenericTypeArguments: true,
213
- },
214
- ],
215
- /**
216
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-misused-new.md
217
- */
218
- '@typescript-eslint/no-misused-new': 'error',
219
- /**
220
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-misused-promises.md
221
- */
222
- '@typescript-eslint/no-misused-promises': 'off',
223
- /**
224
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-namespace.md
225
- */
226
- '@typescript-eslint/no-namespace': 'off',
227
- /**
228
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-non-null-asserted-optional-chain.md
229
- */
230
- '@typescript-eslint/no-non-null-asserted-optional-chain': 'error',
231
- /**
232
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-non-null-assertion.md
233
- */
234
- '@typescript-eslint/no-non-null-assertion': 'warn',
235
- /**
236
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-parameter-properties.md
237
- */
238
- '@typescript-eslint/no-parameter-properties': 'error',
239
- /**
240
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-require-imports.md
241
- */
242
- '@typescript-eslint/no-require-imports': 'error',
243
- /**
244
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-this-alias.md
245
- */
246
- '@typescript-eslint/no-this-alias': 'error',
247
- /**
248
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-throw-literal.md
249
- */
250
- '@typescript-eslint/no-throw-literal': 'off',
251
- /**
252
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-type-alias.md
253
- */
254
- '@typescript-eslint/no-type-alias': [
255
- 'off',
256
- {
257
- allowAliases: 'always',
258
- allowCallbacks: 'always',
259
- allowConditionalTypes: 'always',
260
- allowConstructors: 'never',
261
- allowLiterals: 'in-unions-and-intersections',
262
- allowMappedTypes: 'always',
263
- allowTupleTypes: 'always',
264
- },
265
- ],
266
- /**
267
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unnecessary-boolean-literal-compare.md
268
- */
269
- '@typescript-eslint/no-unnecessary-boolean-literal-compare': 'off',
270
- /**
271
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unnecessary-condition.md
272
- */
273
- '@typescript-eslint/no-unnecessary-condition': 'off',
274
- /**
275
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unnecessary-qualifier.md
276
- */
277
- '@typescript-eslint/no-unnecessary-qualifier': 'off',
278
- /**
279
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unnecessary-type-arguments.md
280
- */
281
- '@typescript-eslint/no-unnecessary-type-arguments': 'off',
282
- /**
283
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unnecessary-type-assertion.md
284
- */
285
- '@typescript-eslint/no-unnecessary-type-assertion': 'off',
286
- /**
287
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unsafe-assignment.md
288
- */
289
- '@typescript-eslint/no-unsafe-assignment': 'off',
290
- /**
291
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unsafe-call.md
292
- */
293
- '@typescript-eslint/no-unsafe-call': 'off',
294
- /**
295
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unsafe-member-access.md
296
- */
297
- '@typescript-eslint/no-unsafe-member-access': 'off',
298
- /**
299
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unsafe-return.md
300
- */
301
- '@typescript-eslint/no-unsafe-return': 'off',
302
- /**
303
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-var-requires.md
304
- */
305
- '@typescript-eslint/no-var-requires': 'error',
306
- /**
307
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-as-const.md
308
- */
309
- '@typescript-eslint/prefer-as-const': 'error',
310
- /**
311
- * We don't care about enums having implicit values.
312
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-enum-initializers.md
313
- */
314
- '@typescript-eslint/prefer-enum-initializers': 'off',
315
- /**
316
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-for-of.md
317
- */
318
- '@typescript-eslint/prefer-for-of': 'error',
319
- /**
320
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-includes.md
321
- */
322
- '@typescript-eslint/prefer-includes': 'off',
323
- /**
324
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-literal-enum-member.md
325
- */
326
- '@typescript-eslint/prefer-literal-enum-member': 'error',
327
- /**
328
- * using ES2015 syntax so this rule can be safetly turned off
329
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-namespace-keyword.md
330
- */
331
- '@typescript-eslint/prefer-namespace-keyword': 'off',
332
- /**
333
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-nullish-coalescing.md
334
- */
335
- '@typescript-eslint/prefer-nullish-coalescing': 'off',
336
- /**
337
- * only set to warn because there are some cases this behavior doesnt work because
338
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-optional-chain.md
339
- */
340
- '@typescript-eslint/prefer-optional-chain': 'warn',
341
- /**
342
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-readonly.md
343
- */
344
- '@typescript-eslint/prefer-readonly': 'off',
345
- /**
346
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-readonly-parameter-types.md
347
- */
348
- '@typescript-eslint/prefer-readonly-parameter-types': 'off',
349
- /**
350
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-reduce-type-parameter.md
351
- */
352
- '@typescript-eslint/prefer-reduce-type-parameter': 'off',
353
- /**
354
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-regexp-exec.md
355
- */
356
- '@typescript-eslint/prefer-regexp-exec': 'off',
357
- /**
358
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-string-starts-ends-with.md
359
- */
360
- '@typescript-eslint/prefer-string-starts-ends-with': 'off',
361
- /**
362
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/prefer-ts-expect-error.md
363
- */
364
- '@typescript-eslint/prefer-ts-expect-error': 'warn',
365
- /**
366
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/promise-function-async.md
367
- */
368
- '@typescript-eslint/promise-function-async': 'off',
369
- /**
370
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/require-array-sort-compare.md
371
- */
372
- '@typescript-eslint/require-array-sort-compare': 'off',
373
- /**
374
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/restrict-plus-operands.md
375
- */
376
- '@typescript-eslint/restrict-plus-operands': 'off',
377
- /**
378
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/restrict-template-expressions.md
379
- */
380
- '@typescript-eslint/restrict-template-expressions': 'off',
381
- /**
382
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/strict-boolean-expressions.md
383
- */
384
- '@typescript-eslint/strict-boolean-expressions': 'off',
385
- /**
386
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/switch-exhaustiveness-check.md
387
- */
388
- '@typescript-eslint/switch-exhaustiveness-check': 'off',
389
- /**
390
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/triple-slash-reference.md
391
- */
392
- '@typescript-eslint/triple-slash-reference': 'error',
393
- /**
394
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/type-annotation-spacing.md
395
- */
396
- '@typescript-eslint/type-annotation-spacing': [
397
- 'error',
398
- {
399
- before: false,
400
- after: true,
401
- overrides: {
402
- arrow: {
403
- before: true,
404
- after: true,
405
- },
406
- },
407
- },
408
- ],
409
- /**
410
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/typedef.md
411
- */
412
- '@typescript-eslint/typedef': [
413
- 'error',
414
- {
415
- arrayDestructuring: false,
416
- arrowParameter: false,
417
- memberVariableDeclaration: false,
418
- objectDestructuring: false,
419
- parameter: false,
420
- propertyDeclaration: true,
421
- variableDeclaration: false,
422
- variableDeclarationIgnoreFunction: false,
423
- },
424
- ],
425
- /**
426
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/unbound-method.md
427
- */
428
- '@typescript-eslint/unbound-method': 'off',
429
- /**
430
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/unified-signatures.md
431
- */
432
- '@typescript-eslint/unified-signatures': 'off',
433
-
434
- // @typescript-eslint Extension Rules
435
- // ==================================================================================
436
- /**
437
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/brace-style.md
438
- */
439
- 'brace-style': 'off',
440
- '@typescript-eslint/brace-style': 'error',
441
- /**
442
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/comma-spacing.md
443
- */
444
- 'comma-spacing': 'off',
445
- '@typescript-eslint/comma-spacing': 'error',
446
- /**
447
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/default-param-last.md
448
- */
449
- 'default-param-last': 'off',
450
- '@typescript-eslint/default-param-last': 'error',
451
- /**
452
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/dot-notation.md
453
- */
454
- 'dot-notation': 'error',
455
- '@typescript-eslint/dot-notation': 'off',
456
- /**
457
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/func-call-spacing.md
458
- */
459
- 'func-call-spacing': 'off',
460
- '@typescript-eslint/func-call-spacing': 'error',
461
- /**
462
- * use prettier instead
463
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/indent.md
464
- */
465
- indent: 'off',
466
- '@typescript-eslint/indent': 'off',
467
- /**
468
- * Allow a mix between the two
469
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/init-declarations.md
470
- */
471
- '@typescript-eslint/init-declarations': 'off',
472
- /**
473
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/keyword-spacing.md
474
- */
475
- 'keyword-spacing': 'off',
476
- '@typescript-eslint/keyword-spacing': 'error',
477
- /**
478
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/lines-between-class-members.md
479
- */
480
- 'lines-between-class-members': 'off',
481
- '@typescript-eslint/lines-between-class-members': [
482
- 'error',
483
- 'always',
484
- {
485
- // base eslint config
486
- exceptAfterSingleLine: true,
487
- // typescript specific
488
- exceptAfterOverload: true,
489
- },
490
- ],
491
- /**
492
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-array-constructor.md
493
- */
494
- 'no-array-constructor': 'off',
495
- '@typescript-eslint/no-array-constructor': 'error',
496
- /**
497
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-dupe-class-members.md
498
- */
499
- 'no-dupe-class-members': 'off',
500
- '@typescript-eslint/no-dupe-class-members': 'error',
501
- /**
502
- * Use prettier
503
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-extra-parens.md
504
- */
505
- 'no-extra-parens': 'off',
506
- '@typescript-eslint/no-extra-parens': 'off',
507
- /**
508
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-extra-semi.md
509
- */
510
- 'no-extra-semi': 'off',
511
- '@typescript-eslint/no-extra-semi': 'error',
512
- /**
513
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-invalid-this.md
514
- */
515
- 'no-invalid-this': 'off',
516
- '@typescript-eslint/no-invalid-this': 'error',
517
- /**
518
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-loss-of-precision.md
519
- */
520
- 'no-loss-of-precision': 'off',
521
- '@typescript-eslint/no-loss-of-precision': 'error',
522
- /**
523
- * https://eslint.org/docs/rules/no-magic-numbers
524
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-magic-numbers.md
525
- */
526
- 'no-magic-numbers': 'off',
527
- '@typescript-eslint/no-magic-numbers': [
528
- 'off',
529
- {
530
- // base eslint configs
531
- ignoreArrayIndexes: true,
532
- ignoreDefaultValues: true,
533
- enforceConst: true,
534
- // typescript specific configs
535
- ignoreEnums: true,
536
- ignoreNumericLiteralTypes: true,
537
- ignoreReadonlyClassProperties: true,
538
- },
539
- ],
540
- /**
541
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-redeclare.md
542
- */
543
- 'no-redeclare': 'off',
544
- '@typescript-eslint/no-redeclare': [
545
- 'error',
546
- {
547
- // prevents variables from being created with global variable naming
548
- builtinGlobals: true,
549
- },
550
- ],
551
- /**
552
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-shadow.md
553
- */
554
- 'no-shadow': 'off',
555
- '@typescript-eslint/no-shadow': [
556
- 'error',
557
- {
558
- // No variables + types with same naming
559
- ignoreTypeValueShadow: false,
560
- },
561
- ],
562
- /**
563
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unused-expressions.md
564
- */
565
- 'no-unused-expressions': 'off',
566
- '@typescript-eslint/no-unused-expressions': 'error',
567
- /**
568
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unused-vars.md
569
- */
570
- 'no-unused-vars': 'off',
571
- '@typescript-eslint/no-unused-vars': [
572
- 'error',
573
- {
574
- ignoreRestSiblings: true,
575
- },
576
- ],
577
- /**
578
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-use-before-define.md
579
- */
580
- 'no-use-before-define': 'off',
581
- '@typescript-eslint/no-use-before-define': 'off',
582
- /**
583
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-useless-constructor.md
584
- */
585
- 'no-useless-constructor': 'off',
586
- '@typescript-eslint/no-useless-constructor': 'error',
587
- /**
588
- * https://eslint.org/docs/rules/quotes
589
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/quotes.md
590
- */
591
- quotes: 'off',
592
- '@typescript-eslint/quotes': [
593
- 'error',
594
- 'single',
595
- {
596
- avoidEscape: true,
597
- allowTemplateLiterals: true,
598
- },
599
- ],
600
- /**
601
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/require-await.md
602
- */
603
- '@typescript-eslint/require-await': 'off',
604
- /**
605
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/return-await.md
606
- */
607
- '@typescript-eslint/return-await': 'off',
608
- /**
609
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/semi.md
610
- */
611
- semi: 'off',
612
- '@typescript-eslint/semi': ['error', 'never'],
613
- /**
614
- * https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/space-before-function-paren.md
615
- */
616
- 'space-before-function-paren': 'off',
617
- '@typescript-eslint/space-before-function-paren': [
618
- 'error',
619
- {
620
- anonymous: 'never',
621
- named: 'never',
622
- asyncArrow: 'always',
623
- },
624
- ],
625
- },
626
- },
627
- ],
628
- }
@@ -1,16 +0,0 @@
1
- version: "3"
2
-
3
- services:
4
- azure-storage:
5
- image: mcr.microsoft.com/azure-storage/azurite:3.18.0
6
- restart: always
7
- command: "azurite --loose --blobHost 0.0.0.0 --tableHost 0.0.0.0 --queueHost 0.0.0.0"
8
- ports:
9
- - "10000:10000"
10
- - "10001:10001"
11
- - "10002:10002"
12
- volumes:
13
- - ./azurestoragedata:/data"
14
-
15
- volumes:
16
- azurestoragedata:
@@ -1,13 +0,0 @@
1
- import path from 'path'
2
- import type { GenerateURL } from '../../types'
3
-
4
- interface Args {
5
- containerName: string
6
- baseURL: string
7
- }
8
-
9
- export const getGenerateURL =
10
- ({ containerName, baseURL }: Args): GenerateURL =>
11
- ({ filename, prefix = '' }) => {
12
- return `${baseURL}/${containerName}/${path.posix.join(prefix, filename)}`
13
- }