eslint-plugin-use-agnostic 2.0.3 → 2.0.4

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.
@@ -141,7 +141,7 @@ export const AT_SERVER_FUNCTIONS =
141
141
  export const AT_CLIENT_CONTEXTS =
142
142
  commentVariablesData.directive21["use client contexts"].atStrategy.value;
143
143
  // export const AT_AGNOSTIC_CONDITIONS =
144
- // commentVariablesData.directive21["use agnostic conditions"].atStrategy.value; // Agnostic Conditions Modules no longer output from Agnostic Strategies Modules.
144
+ // commentVariablesData.directive21["use agnostic conditions"].atStrategy.value; // $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#KINDSSIMPLE Modules no longer output from Agnostic Strategies Modules.
145
145
 
146
146
  // commented strategies array
147
147
  /** @type {CommentedStrategies} */
@@ -209,12 +209,12 @@ export const commentedDirectives_verificationReports = Object.freeze({
209
209
  /* commentedDirectives_blockedImports */
210
210
 
211
211
  /**
212
- * Makes a blockedImport object for the identified blocked import at hand.
212
+ * $COMMENT#JSDOC#DEFINITIONS#AGNOSTIC20#MAKEBLOCKEDIMPORT
213
213
  * @template {CommentedDirective} T
214
214
  * @template {CommentedDirective} U
215
- * @param {T} currentFileCommentedDirective The current file's commented directive.
216
- * @param {U} importedFileCommentedDirective The imported file's commented directive.
217
- * @returns The blockedImport object for the identified blocked import at hand.
215
+ * @param {T} currentFileCommentedDirective $COMMENT#JSDOC#PARAMS#DIRECTIVE21#CURRENTFILECOMMENTEDDIRECTIVE
216
+ * @param {U} importedFileCommentedDirective $COMMENT#JSDOC#PARAMS#DIRECTIVE21#IMPORTEDFILECOMMENTEDDIRECTIVE
217
+ * @returns $COMMENT#JSDOC#RETURNS#AGNOSTIC20#MAKEBLOCKEDIMPORT
218
218
  */
219
219
  export const makeBlockedImport = (
220
220
  currentFileCommentedDirective,
@@ -235,244 +235,244 @@ export const makeBlockedImport = (
235
235
 
236
236
  export const commentedDirectives_blockedImports = Object.freeze({
237
237
  [USE_SERVER_LOGICS]: Object.freeze([
238
- // USE_SERVER_LOGICS Prime Server Logics can compose with one another.
238
+ // USE_SERVER_LOGICS $COMMENT#DIRECTIVE21#USE_SERVER_LOGICS#USE_SERVER_LOGICS
239
239
  makeBlockedImport(
240
240
  USE_SERVER_LOGICS,
241
241
  USE_CLIENT_LOGICS,
242
- ) /* Prime Client Logics should never leak to the server. */,
243
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics can run safely on the server just like they can on the client.
244
- // USE_SERVER_COMPONENTS Lineal Server Components are OK to be composed with Prime Server Logics as long as the Prime Server Logics Module, by convention, does not export React components.
242
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#CLIENTNEVERSERVER */,
243
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCANSERVERCLIENT
244
+ // USE_SERVER_COMPONENTS $COMMENT#DIRECTIVE21#USE_SERVER_LOGICS#USE_SERVER_COMPONENTS
245
245
  makeBlockedImport(
246
246
  USE_SERVER_LOGICS,
247
247
  USE_CLIENT_COMPONENTS,
248
- ) /* Lineal Client Components, like any Client Components, cannot be tinkered with on the server. */,
249
- // USE_AGNOSTIC_COMPONENTS Lineal Agnostic Components can be composed with any Prime Environment Logics agnostically, as long as the Prime Environment Logics Module, by convention, does not export React components.
250
- // USE_SERVER_FUNCTIONS (Special) Server Functions, being able to import one another, can compose and do so via Prime Server Logics, despite this method seeming superfluous at first glance. (Perhaps a preferrable use case for this has been found or could be found either today or in the future.)
248
+ ) /* $COMMENT#DIRECTIVE21#USE_SERVER_LOGICS#USE_CLIENT_COMPONENTS */,
249
+ // USE_AGNOSTIC_COMPONENTS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCOMPONENTSCANANY
250
+ // USE_SERVER_FUNCTIONS $COMMENT#DIRECTIVE21#USE_SERVER_LOGICS#USE_SERVER_FUNCTIONS
251
251
  makeBlockedImport(
252
252
  USE_SERVER_LOGICS,
253
253
  USE_CLIENT_CONTEXTS,
254
- ) /* (Special) Client Contexts Components, like any Client Components, cannot be tinkered with on the server. */,
255
- // USE_AGNOSTIC_CONDITIONS (Special) Agnostic Conditions Components and/or Logics, as if they were Lineal Agnostic Components and/or Prime Agnostic Logics themselves, can render safely on the server just like they can on the client.
254
+ ) /* $COMMENT#DIRECTIVE21#USE_SERVER_LOGICS#USE_CLIENT_CONTEXTS */,
255
+ // USE_AGNOSTIC_CONDITIONS $COMMENT#DIRECTIVE21#USE_SERVER_COMPONENTS#USE_AGNOSTIC_CONDITIONS
256
256
  makeBlockedImport(
257
257
  USE_SERVER_LOGICS,
258
258
  USE_AGNOSTIC_STRATEGIES,
259
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
259
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
260
260
  ]),
261
261
  [USE_CLIENT_LOGICS]: Object.freeze([
262
262
  makeBlockedImport(
263
263
  USE_CLIENT_LOGICS,
264
264
  USE_SERVER_LOGICS,
265
- ) /* Prime Server Logics should never leak to the client. */,
266
- // USE_CLIENT_LOGICS Prime Client Logics can compose with one another.
267
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics can run safely on the client just like they can on the server.
265
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#SERVERNEVERCLIENT */,
266
+ // USE_CLIENT_LOGICS $COMMENT#DIRECTIVE21#USE_CLIENT_LOGICS#USE_CLIENT_LOGICS
267
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCANCLIENTSERVER
268
268
  makeBlockedImport(
269
269
  USE_CLIENT_LOGICS,
270
270
  USE_SERVER_COMPONENTS,
271
- ) /* Lineal Server Components cannot be tinkered with on the client. */,
272
- // USE_CLIENT_COMPONENTS Lineal Client Components, like any Client Components, are OK to be composed with Prime Client Logics as long as the Prime Client Logics Module, by convention, does not export React components.
273
- // USE_AGNOSTIC_COMPONENTS Lineal Agnostic Components can be composed with any Prime Environment Logics agnostically, as long as the Prime Environment Logics Module, by convention, does not export React components.
274
- // USE_SERVER_FUNCTIONS (Special) Server Functions can technically be attached to any Client Components being tinkered with within Client Logics Modules.
275
- // USE_CLIENT_CONTEXTS (Special) Client Contexts Components, like any Client Components, are OK to be composed with Prime Client Logics as long as the Prime Client Logics Module, by convention, does not export React components.
276
- // USE_AGNOSTIC_CONDITIONS (Special) Agnostic Conditions Components and/or Logics, as if they were Lineal Agnostic Components and/or Prime Agnostic Logics themselves, can render safely on the client just like they can on the server.
271
+ ) /* $COMMENT#DIRECTIVE21#USE_CLIENT_LOGICS#USE_SERVER_COMPONENTS */,
272
+ // USE_CLIENT_COMPONENTS $COMMENT#DIRECTIVE21#USE_CLIENT_LOGICS#USE_CLIENT_COMPONENTS
273
+ // USE_AGNOSTIC_COMPONENTS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCOMPONENTSCANANY
274
+ // USE_SERVER_FUNCTIONS $COMMENT#DIRECTIVE21#USE_CLIENT_LOGICS#USE_SERVER_FUNCTIONS
275
+ // USE_CLIENT_CONTEXTS $COMMENT#DIRECTIVE21#USE_CLIENT_LOGICS#USE_CLIENT_CONTEXTS
276
+ // USE_AGNOSTIC_CONDITIONS $COMMENT#DIRECTIVE21#USE_CLIENT_COMPONENTS#USE_AGNOSTIC_CONDITIONS
277
277
  makeBlockedImport(
278
278
  USE_CLIENT_LOGICS,
279
279
  USE_AGNOSTIC_STRATEGIES,
280
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
280
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
281
281
  ]),
282
282
  [USE_AGNOSTIC_LOGICS]: Object.freeze([
283
283
  makeBlockedImport(
284
284
  USE_AGNOSTIC_LOGICS,
285
285
  USE_SERVER_LOGICS,
286
- ) /* Prime Server Logics cannot run on both the server and the client. */,
286
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#SERVERLOGICSCANTBOTH */,
287
287
  makeBlockedImport(
288
288
  USE_AGNOSTIC_LOGICS,
289
289
  USE_CLIENT_LOGICS,
290
- ) /* Prime Client Logics cannot run on both the server and the client. */,
291
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics can compose with one another.
290
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#CLIENTLOGICSCANTBOTH */,
291
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_LOGICS#USE_AGNOSTIC_LOGICS
292
292
  makeBlockedImport(
293
293
  USE_AGNOSTIC_LOGICS,
294
294
  USE_SERVER_COMPONENTS,
295
- ) /* Lineal Server Components cannot be tinkered with on both the server and the client. */,
295
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_LOGICS#USE_SERVER_COMPONENTS */,
296
296
  makeBlockedImport(
297
297
  USE_AGNOSTIC_LOGICS,
298
298
  USE_CLIENT_COMPONENTS,
299
- ) /* Lineal Client Components, like any Client Components, cannot be tinkered with on both the server and the client. */,
300
- // USE_AGNOSTIC_COMPONENTS Lineal Agnostic Components can be composed with any Prime Environment Logics agnostically, as long as the Prime Environment Logics Module, by convention, does not export React components.
299
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_LOGICS#USE_CLIENT_COMPONENTS */,
300
+ // USE_AGNOSTIC_COMPONENTS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCOMPONENTSCANANY
301
301
  makeBlockedImport(
302
302
  USE_AGNOSTIC_LOGICS,
303
303
  USE_SERVER_FUNCTIONS,
304
- ) /* (Special) Server Functions can be modified on the server and on the client, but their use cases on both environments are not one-to-one compatible, since they're being addressed as they are on the server and addressed as references on the client. */,
304
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_LOGICS#USE_SERVER_FUNCTIONS */,
305
305
  makeBlockedImport(
306
306
  USE_AGNOSTIC_LOGICS,
307
307
  USE_CLIENT_CONTEXTS,
308
- ) /* (Special) Client Contexts Components, like any Client Components, cannot be tinkered with on both the server and the client. */,
308
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_LOGICS#USE_CLIENT_CONTEXTS */,
309
309
  makeBlockedImport(
310
310
  USE_AGNOSTIC_LOGICS,
311
311
  USE_AGNOSTIC_CONDITIONS,
312
- ) /* (Special) Agnostic Conditions Modules cannot be imported in the (Abstract) Agnostic Environment, only strictly on the server or strictly on the client. */,
312
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#INVALIDENVIRONMENT */,
313
313
  makeBlockedImport(
314
314
  USE_AGNOSTIC_LOGICS,
315
315
  USE_AGNOSTIC_STRATEGIES,
316
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
316
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
317
317
  ]),
318
318
  [USE_SERVER_COMPONENTS]: Object.freeze([
319
- // USE_SERVER_LOGICS Prime Server Logics, being logic from the server, can safely support Lineal Server Components.
319
+ // USE_SERVER_LOGICS $COMMENT#DIRECTIVE21#USE_SERVER_COMPONENTS#USE_SERVER_LOGICS
320
320
  makeBlockedImport(
321
321
  USE_SERVER_COMPONENTS,
322
322
  USE_CLIENT_LOGICS,
323
- ) /* Prime Client Logics should never leak to the server. */,
324
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics can run safely on the server just like they can on the client.
325
- // USE_SERVER_COMPONENTS Lineal Server Components can compose with one another, now that thanks to the inclusion of Agnostic Components they are actual Server Components.
326
- // USE_CLIENT_COMPONENTS Lineal Client Components can be nested inside Lineal Server Components to create client boundaries when the root of the application is planted on the server.
327
- // USE_AGNOSTIC_COMPONENTS Lineal Agnostic Components can render safely on the server just like they can on the client.
328
- // USE_SERVER_FUNCTIONS (Special) Server Functions can be passed to imported Client Components within Lineal Server Components Modules, even though indeed Lineal Server Components Modules and Lineal Server Components can make their own Server Functions through inline `'use server'` directives.
329
- // USE_CLIENT_CONTEXTS (Special) Client Contexts Components can be nested inside Lineal Server Components to wrap some of the tree with client state accessible through child Client Components, and to pass through Server Components when the root of the application is planted on the server.
330
- // USE_AGNOSTIC_CONDITIONS (Special) Agnostic Conditions Components and/or Logics, as if they were Lineal Agnostic Components and/or Prime Agnostic Logics themselves, can render safely on the server just like they can on the client.
323
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#CLIENTNEVERSERVER */,
324
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCANSERVERCLIENT
325
+ // USE_SERVER_COMPONENTS $COMMENT#DIRECTIVE21#USE_SERVER_COMPONENTS#USE_SERVER_COMPONENTS
326
+ // USE_CLIENT_COMPONENTS $COMMENT#DIRECTIVE21#USE_SERVER_COMPONENTS#USE_CLIENT_COMPONENTS
327
+ // USE_AGNOSTIC_COMPONENTS $COMMENT#DIRECTIVE21#USE_SERVER_COMPONENTS#USE_AGNOSTIC_COMPONENTS
328
+ // USE_SERVER_FUNCTIONS $COMMENT#DIRECTIVE21#USE_SERVER_COMPONENTS#USE_SERVER_FUNCTIONS
329
+ // USE_CLIENT_CONTEXTS $COMMENT#DIRECTIVE21#USE_SERVER_COMPONENTS#USE_CLIENT_CONTEXTS
330
+ // USE_AGNOSTIC_CONDITIONS $COMMENT#DIRECTIVE21#USE_SERVER_COMPONENTS#USE_AGNOSTIC_CONDITIONS
331
331
  makeBlockedImport(
332
332
  USE_SERVER_COMPONENTS,
333
333
  USE_AGNOSTIC_STRATEGIES,
334
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
334
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
335
335
  ]),
336
336
  [USE_CLIENT_COMPONENTS]: Object.freeze([
337
337
  makeBlockedImport(
338
338
  USE_CLIENT_COMPONENTS,
339
339
  USE_SERVER_LOGICS,
340
- ) /* Prime Server Logics should never leak to the client. */,
341
- // USE_CLIENT_LOGICS Prime Client Logics, being logic from the client, can safely support Lineal Client Components, like any Client Components.
342
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics can run safely on the client just like they can on the server.
340
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#SERVERNEVERCLIENT */,
341
+ // USE_CLIENT_LOGICS $COMMENT#DIRECTIVE21#USE_CLIENT_COMPONENTS#USE_CLIENT_LOGICS
342
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCANCLIENTSERVER
343
343
  makeBlockedImport(
344
344
  USE_CLIENT_COMPONENTS,
345
345
  USE_SERVER_COMPONENTS,
346
- ) /* Lineal Server Components cannot be the children of Lineal Client Components. */,
347
- // USE_CLIENT_COMPONENTS Lineal Client Components can compose with one another.
348
- // USE_AGNOSTIC_COMPONENTS Lineal Agnostic Components can render safely on the client just like they can on the server.
349
- // USE_SERVER_FUNCTIONS (Special) Server Functions can be specifically triggered by Client Components.
350
- // USE_CLIENT_CONTEXTS (Special) Client Contexts Components can effectively become Lineal and only render their children on the client via this mechanism since, by a Client Contexts Component being the child of a Lineal Client Component, the Client Contexts Component's children become the grandchildren of an ancestor Lineal Client Component, enforcing them to render exclusively on the client.
351
- // USE_AGNOSTIC_CONDITIONS (Special) Agnostic Conditions Components and/or Logics, as if they were Lineal Agnostic Components and/or Prime Agnostic Logics themselves, can render safely on the client just like they can on the server.
346
+ ) /* $COMMENT#DIRECTIVE21#USE_CLIENT_COMPONENTS#USE_SERVER_COMPONENTS */,
347
+ // USE_CLIENT_COMPONENTS $COMMENT#DIRECTIVE21#USE_CLIENT_COMPONENTS#USE_CLIENT_COMPONENTS
348
+ // USE_AGNOSTIC_COMPONENTS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCOMPONENTSRENDERANY
349
+ // USE_SERVER_FUNCTIONS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#SERVERFUNCTIONSCLIENT
350
+ // USE_CLIENT_CONTEXTS $COMMENT#DIRECTIVE21#USE_CLIENT_COMPONENTS#USE_CLIENT_CONTEXTS
351
+ // USE_AGNOSTIC_CONDITIONS $COMMENT#DIRECTIVE21#USE_CLIENT_COMPONENTS#USE_AGNOSTIC_CONDITIONS
352
352
  makeBlockedImport(
353
353
  USE_CLIENT_COMPONENTS,
354
354
  USE_AGNOSTIC_STRATEGIES,
355
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
355
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
356
356
  ]),
357
357
  [USE_AGNOSTIC_COMPONENTS]: Object.freeze([
358
358
  makeBlockedImport(
359
359
  USE_AGNOSTIC_COMPONENTS,
360
360
  USE_SERVER_LOGICS,
361
- ) /* Prime Server Logics cannot run on both the server and the client. */,
361
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#SERVERLOGICSCANTBOTH */,
362
362
  makeBlockedImport(
363
363
  USE_AGNOSTIC_COMPONENTS,
364
364
  USE_CLIENT_LOGICS,
365
- ) /* Prime Client Logics cannot run on both the server and the client. */,
366
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics, being environment-agnostic logic, can safely support any Agnostic Components.
365
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#CLIENTLOGICSCANTBOTH */,
366
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_COMPONENTS#USE_AGNOSTIC_LOGICS
367
367
  makeBlockedImport(
368
368
  USE_AGNOSTIC_COMPONENTS,
369
369
  USE_SERVER_COMPONENTS,
370
- ) /* Lineal Server Components, unlike Lineal Client Components, cannot make silos of their own once on the opposing environment (the client in this case), and therefore cannot be executed from the client, making them unable to execute agnostically from both the server and the client. */,
371
- // USE_CLIENT_COMPONENTS Lineal Client Components can be nested inside Lineal Agnostic Components to create client boundaries when the root of the application is planted on the server.
372
- // USE_AGNOSTIC_COMPONENTS Lineal Agnostic Components can compose with one another.
373
- // USE_SERVER_FUNCTIONS (Special) Server Functions can be passed to Client Components as props when Client Components are also legally imported into Agnostic Components Modules.
374
- // USE_CLIENT_CONTEXTS (Special) Client Contexts Components can be nested inside Lineal Agnostic Components to wrap some of the tree with client state accessible through child Client Components, and to pass through Server Components — if still on the Server Tree — when the root of the application is planted on the server.
370
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_COMPONENTS#USE_SERVER_COMPONENTS */,
371
+ // USE_CLIENT_COMPONENTS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_COMPONENTS#USE_CLIENT_COMPONENTS
372
+ // USE_AGNOSTIC_COMPONENTS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_COMPONENTS#USE_AGNOSTIC_COMPONENTS
373
+ // USE_SERVER_FUNCTIONS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_COMPONENTS#USE_SERVER_FUNCTIONS
374
+ // USE_CLIENT_CONTEXTS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_COMPONENTS#USE_CLIENT_CONTEXTS
375
375
  makeBlockedImport(
376
376
  USE_AGNOSTIC_COMPONENTS,
377
377
  USE_AGNOSTIC_CONDITIONS,
378
- ) /* (Special) Agnostic Conditions Modules cannot be imported in the (Abstract) Agnostic Environment, only strictly on the server or strictly on the client. */,
378
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#INVALIDENVIRONMENT */,
379
379
  makeBlockedImport(
380
380
  USE_AGNOSTIC_COMPONENTS,
381
381
  USE_AGNOSTIC_STRATEGIES,
382
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
382
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
383
383
  ]),
384
384
  [USE_SERVER_FUNCTIONS]: Object.freeze([
385
- // USE_SERVER_LOGICS Prime Server Logics, being logic from the server, can safely support (Special) Server Functions.
385
+ // USE_SERVER_LOGICS $COMMENT#DIRECTIVE21#USE_SERVER_FUNCTIONS#USE_SERVER_LOGICS
386
386
  makeBlockedImport(
387
387
  USE_SERVER_FUNCTIONS,
388
388
  USE_CLIENT_LOGICS,
389
- ) /* Prime Client Logics should never leak to the server. */,
390
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics can run safely on the server just like they can on the client.
389
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#CLIENTNEVERSERVER */,
390
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCANSERVERCLIENT
391
391
  makeBlockedImport(
392
392
  USE_SERVER_FUNCTIONS,
393
393
  USE_SERVER_COMPONENTS,
394
- ) /* Lineal Server Components aren't allowed because (Special) Server Functions have no business working with React Components. */,
394
+ ) /* $COMMENT#DIRECTIVE21#USE_SERVER_FUNCTIONS#USE_SERVER_COMPONENTS */,
395
395
  makeBlockedImport(
396
396
  USE_SERVER_FUNCTIONS,
397
397
  USE_CLIENT_COMPONENTS,
398
- ) /* Lineal Client Components aren't allowed because (Special) Server Functions have no business working with React Components. */,
398
+ ) /* $COMMENT#DIRECTIVE21#USE_SERVER_FUNCTIONS#USE_CLIENT_COMPONENTS */,
399
399
  makeBlockedImport(
400
400
  USE_SERVER_FUNCTIONS,
401
401
  USE_AGNOSTIC_COMPONENTS,
402
- ) /* Lineal Agnostic Components aren't allowed because (Special) Server Functions have no business working with React Components. */,
403
- // USE_SERVER_FUNCTIONS (Special) Server Functions, even though they don't need to import one another and the same results can be generated via Prime Server Logics for the outcome of a single Server Function, can still compose with one another. (Perhaps a preferrable use case for this has been found or could be found either today or in the future.)
402
+ ) /* $COMMENT#DIRECTIVE21#USE_SERVER_FUNCTIONS#USE_AGNOSTIC_COMPONENTS */,
403
+ // USE_SERVER_FUNCTIONS $COMMENT#DIRECTIVE21#USE_SERVER_FUNCTIONS#USE_SERVER_FUNCTIONS
404
404
  makeBlockedImport(
405
405
  USE_SERVER_FUNCTIONS,
406
406
  USE_CLIENT_CONTEXTS,
407
- ) /* (Special) Client Contexts Components aren't allowed because (Special) Server Functions have no business working with React Components. */,
407
+ ) /* $COMMENT#DIRECTIVE21#USE_SERVER_FUNCTIONS#USE_CLIENT_CONTEXTS */,
408
408
  makeBlockedImport(
409
409
  USE_SERVER_FUNCTIONS,
410
410
  USE_AGNOSTIC_CONDITIONS,
411
- ) /* (Special) Agnostic Conditions Components and/or Logics aren't allowed because (Special) Server Functions have no business working with React Components. */,
411
+ ) /* $COMMENT#DIRECTIVE21#USE_SERVER_FUNCTIONS#USE_AGNOSTIC_CONDITIONS */,
412
412
  makeBlockedImport(
413
413
  USE_SERVER_FUNCTIONS,
414
414
  USE_AGNOSTIC_STRATEGIES,
415
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
415
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
416
416
  ]),
417
417
  [USE_CLIENT_CONTEXTS]: Object.freeze([
418
418
  makeBlockedImport(
419
419
  USE_CLIENT_CONTEXTS,
420
420
  USE_SERVER_LOGICS,
421
- ) /* Prime Server Logics should never leak to the client. */,
422
- // USE_CLIENT_LOGICS Prime Client Logics, being logic from the client, can safely support (Special) Client Contexts Components, like any Client Components.
423
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics can run safely on the client just like they can on the server.
421
+ ) /* $COMMENT#DIRECTIVE21#FORALIASVARIABLES#SERVERNEVERCLIENT */,
422
+ // USE_CLIENT_LOGICS $COMMENT#DIRECTIVE21#USE_CLIENT_CONTEXTS#USE_CLIENT_LOGICS
423
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCANCLIENTSERVER
424
424
  makeBlockedImport(
425
425
  USE_CLIENT_CONTEXTS,
426
426
  USE_SERVER_COMPONENTS,
427
- ) /* Lineal Server Components may only pass through (Special) Client Contexts Components via the children prop within Server Components Modules. */,
428
- // USE_CLIENT_COMPONENTS Lineal Client Components can create client boundaries within (Special) Client Contexts Components.
429
- // USE_AGNOSTIC_COMPONENTS Lineal Agnostic Components can render safely on the client just like they can on the server.
430
- // USE_SERVER_FUNCTIONS (Special) Server Functions can be specifically triggered by Client Components.
431
- // USE_CLIENT_CONTEXTS (Special) Client Contexts Components can compose with one another.
432
- // USE_AGNOSTIC_CONDITIONS (Special) Agnostic Conditions Components and/or Logics, as if they were Lineal Agnostic Components and/or Prime Agnostic Logics themselves, can render safely on the client just like they can on the server.
427
+ ) /* $COMMENT#DIRECTIVE21#USE_CLIENT_CONTEXTS#USE_SERVER_COMPONENTS */,
428
+ // USE_CLIENT_COMPONENTS $COMMENT#DIRECTIVE21#USE_CLIENT_CONTEXTS#USE_CLIENT_COMPONENTS
429
+ // USE_AGNOSTIC_COMPONENTS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#AGNOSTICCOMPONENTSRENDERANY
430
+ // USE_SERVER_FUNCTIONS $COMMENT#DIRECTIVE21#FORALIASVARIABLES#SERVERFUNCTIONSCLIENT
431
+ // USE_CLIENT_CONTEXTS $COMMENT#DIRECTIVE21#USE_CLIENT_CONTEXTS#USE_CLIENT_CONTEXTS
432
+ // USE_AGNOSTIC_CONDITIONS $COMMENT#DIRECTIVE21#USE_CLIENT_COMPONENTS#USE_AGNOSTIC_CONDITIONS
433
433
  makeBlockedImport(
434
434
  USE_CLIENT_CONTEXTS,
435
435
  USE_AGNOSTIC_STRATEGIES,
436
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
436
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
437
437
  ]),
438
438
  [USE_AGNOSTIC_CONDITIONS]: Object.freeze([
439
- // USE_SERVER_LOGICS Prime Server Logics are to be paired as `LogicForServer` utilities with `LogicForClient` utilities to form (Special) Agnostic Conditions Logics. The `LogicForServer` is always the first assigned. The exported variable should be prefixed by `utilize-`, like `utilizeUtility`.
440
- // USE_CLIENT_LOGICS Prime Client Logics are to be paired as `LogicForClient` utilities with `LogicForServer` utilities to form (Special) Agnostic Conditions Logics. The `LogicForClient` is always the last assigned. The exported variable should be prefixed by `utilize-`, like `utilizeUtility`.
441
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics can take the place of `LogicForServer` and/or `LogicForClient` utilities to form (Special) Agnostic Conditions Logics. The exported variable should be prefixed by `utilize-`, like `utilizeUtility`.
442
- // USE_SERVER_COMPONENTS Lineal Server Components are to be paired as `ComponentForServer` components with `ComponentForClient` components to form (Special) Agnostic Conditions Components. The `ComponentForServer` is always the first assigned. The exported variable should be in PascalCase, like `ReactComponent`.
443
- // USE_CLIENT_COMPONENTS Lineal Client Components are to be paired as `ComponentForClient` components with `ComponentForServer` components to form (Special) Agnostic Conditions Components. The `ComponentForClient` is always the last assigned. The exported variable should be in PascalCase, like `ReactComponent`.
444
- // USE_AGNOSTIC_COMPONENTS Lineal Agnostic Components can take the place of `ComponentForServer` and/or `ComponentForClient` components to form (Special) Agnostic Conditions Components. The exported variable should be in PascalCase, like `ReactComponent`.
439
+ // USE_SERVER_LOGICS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#USE_SERVER_LOGICS
440
+ // USE_CLIENT_LOGICS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#USE_CLIENT_LOGICS
441
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#USE_AGNOSTIC_LOGICS
442
+ // USE_SERVER_COMPONENTS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#USE_SERVER_COMPONENTS
443
+ // USE_CLIENT_COMPONENTS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#USE_CLIENT_COMPONENTS
444
+ // USE_AGNOSTIC_COMPONENTS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#USE_AGNOSTIC_COMPONENTS
445
445
  makeBlockedImport(
446
446
  USE_AGNOSTIC_CONDITIONS,
447
447
  USE_SERVER_FUNCTIONS,
448
- ) /* (Special) Server Functions aren't allowed because they do not have 1-to-1 behavioral equivalents for the client that would satisfy (Special) Agnostic Conditions Modules. */,
449
- // USE_CLIENT_CONTEXTS (Special) Client Contexts Components can actually be used as `ComponentForClient` arguments for (Special) Agnostic Conditions Components notably as counterparts to similar passthrough components selected as `ComponentForServer` arguments.
448
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#USE_SERVER_FUNCTIONS */,
449
+ // USE_CLIENT_CONTEXTS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#USE_CLIENT_CONTEXTS
450
450
  makeBlockedImport(
451
451
  USE_AGNOSTIC_CONDITIONS,
452
452
  USE_AGNOSTIC_CONDITIONS,
453
- ) /* (Special) Agnostic Conditions Modules cannot be imported in the (Abstract) Agnostic Environment, only strictly on the server or strictly on the client. */,
453
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#INVALIDENVIRONMENT */,
454
454
  makeBlockedImport(
455
455
  USE_AGNOSTIC_CONDITIONS,
456
456
  USE_AGNOSTIC_STRATEGIES,
457
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
457
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
458
458
  ]),
459
459
  [USE_AGNOSTIC_STRATEGIES]: Object.freeze([
460
- // USE_SERVER_LOGICS Prime Server Logics allowed, because (Special) Agnostic Strategies Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) Agnostic Conditions Modules which cannot be imported in the (Abstract) Agnostic Environment.
461
- // USE_CLIENT_LOGICS Prime Client Logics allowed, because (Special) Agnostic Strategies Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) Agnostic Conditions Modules which cannot be imported in the (Abstract) Agnostic Environment.
462
- // USE_AGNOSTIC_LOGICS Prime Agnostic Logics allowed, because (Special) Agnostic Strategies Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) Agnostic Conditions Modules which cannot be imported in the (Abstract) Agnostic Environment.
463
- // USE_SERVER_COMPONENTS Lineal Server Components allowed, because (Special) Agnostic Strategies Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) Agnostic Conditions Modules which cannot be imported in the (Abstract) Agnostic Environment.
464
- // USE_CLIENT_COMPONENTS Lineal Client Components allowed, because (Special) Agnostic Strategies Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) Agnostic Conditions Modules which cannot be imported in the (Abstract) Agnostic Environment.
465
- // USE_AGNOSTIC_COMPONENTS Lineal Agnostic Components allowed, because (Special) Agnostic Strategies Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) Agnostic Conditions Modules which cannot be imported in the (Abstract) Agnostic Environment.
466
- // USE_SERVER_FUNCTIONS (Special) Server Functions allowed, because (Special) Agnostic Strategies Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) Agnostic Conditions Modules which cannot be imported in the (Abstract) Agnostic Environment.
467
- // USE_CLIENT_CONTEXTS (Special) Client Contexts Components allowed, because (Special) Agnostic Strategies Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) Agnostic Conditions Modules which cannot be imported in the (Abstract) Agnostic Environment.
460
+ // USE_SERVER_LOGICS $COMMENT#DIRECTIVE21#USE_SERVER_LOGICS#KINDS $COMMENT#AGNOSTIC20#FORCOMPOSEDVARIABLES#ALLOWEDBECAUSE $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#SPECIALS Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#KINDSSIMPLE Modules which cannot be imported in the (Abstract) Agnostic Environment.
461
+ // USE_CLIENT_LOGICS $COMMENT#DIRECTIVE21#USE_CLIENT_LOGICS#KINDS $COMMENT#AGNOSTIC20#FORCOMPOSEDVARIABLES#ALLOWEDBECAUSE $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#SPECIALS Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#KINDSSIMPLE Modules which cannot be imported in the (Abstract) Agnostic Environment.
462
+ // USE_AGNOSTIC_LOGICS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_LOGICS#KINDS $COMMENT#AGNOSTIC20#FORCOMPOSEDVARIABLES#ALLOWEDBECAUSE $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#SPECIALS Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#KINDSSIMPLE Modules which cannot be imported in the (Abstract) Agnostic Environment.
463
+ // USE_SERVER_COMPONENTS $COMMENT#DIRECTIVE21#USE_SERVER_COMPONENTS#KINDS $COMMENT#AGNOSTIC20#FORCOMPOSEDVARIABLES#ALLOWEDBECAUSE $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#SPECIALS Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#KINDSSIMPLE Modules which cannot be imported in the (Abstract) Agnostic Environment.
464
+ // USE_CLIENT_COMPONENTS $COMMENT#DIRECTIVE21#USE_CLIENT_COMPONENTS#KINDS $COMMENT#AGNOSTIC20#FORCOMPOSEDVARIABLES#ALLOWEDBECAUSE $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#SPECIALS Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#KINDSSIMPLE Modules which cannot be imported in the (Abstract) Agnostic Environment.
465
+ // USE_AGNOSTIC_COMPONENTS $COMMENT#DIRECTIVE21#USE_AGNOSTIC_COMPONENTS#KINDS $COMMENT#AGNOSTIC20#FORCOMPOSEDVARIABLES#ALLOWEDBECAUSE $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#SPECIALS Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#KINDSSIMPLE Modules which cannot be imported in the (Abstract) Agnostic Environment.
466
+ // USE_SERVER_FUNCTIONS $COMMENT#DIRECTIVE21#USE_SERVER_FUNCTIONS#SPECIALS $COMMENT#AGNOSTIC20#FORCOMPOSEDVARIABLES#ALLOWEDBECAUSE $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#SPECIALS Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#KINDSSIMPLE Modules which cannot be imported in the (Abstract) Agnostic Environment.
467
+ // USE_CLIENT_CONTEXTS $COMMENT#DIRECTIVE21#USE_CLIENT_CONTEXTS#SPECIALS $COMMENT#AGNOSTIC20#FORCOMPOSEDVARIABLES#ALLOWEDBECAUSE $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#SPECIALS Modules can import all known modules except Special Agnostic Modules, meaning themselves as file generators that should not be imported directly and (Special) $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#KINDSSIMPLE Modules which cannot be imported in the (Abstract) Agnostic Environment.
468
468
  makeBlockedImport(
469
469
  USE_AGNOSTIC_STRATEGIES,
470
470
  USE_AGNOSTIC_CONDITIONS,
471
- ) /* (Special) Agnostic Conditions Modules cannot be imported in the (Abstract) Agnostic Environment, only strictly on the server or strictly on the client. */,
471
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_CONDITIONS#INVALIDENVIRONMENT */,
472
472
  makeBlockedImport(
473
473
  USE_AGNOSTIC_STRATEGIES,
474
474
  USE_AGNOSTIC_STRATEGIES,
475
- ) /* (Special) Agnostic Strategies Modules cannot be imported by any of the known modules, since given that Agnostic Strategies Modules generate strategized files, they need to be imported via their strategized files (like those ending in `.serverLogics.ts`) instead. */,
475
+ ) /* $COMMENT#DIRECTIVE21#USE_AGNOSTIC_STRATEGIES#INVALID */,
476
476
  ]),
477
477
  });
478
478
 
@@ -1,3 +1,8 @@
1
+ import path from "path";
2
+
3
+ import ts from "typescript";
4
+ import { ResolverFactory } from "oxc-resolver";
5
+
1
6
  import {
2
7
  reExportNotSameMessageId,
3
8
  importBreaksCommentedImportRulesMessageId,
@@ -11,6 +16,7 @@ import {
11
16
  missingChildrenMessageId,
12
17
  noRenderPropMessageId,
13
18
  noOnOnElementsMessageId,
19
+ EXTENSIONS,
14
20
  } from "../../../_commons/constants/bases.js";
15
21
  import {
16
22
  currentFileCommentedDirective,
@@ -76,10 +82,25 @@ In this context, {{ ${specificFailure} }} `,
76
82
  create: (context) => {
77
83
  const result = currentFileFlow(context);
78
84
 
79
- const reactFolder = /** @type {string} */ (context.settings.reactFolder);
80
- const rootPath = /** @type {string} */ (context.settings.rootPath);
81
- // make the resolver by resolving the TypeScript from the rootPath
82
- // pass the resolver to importsFlow, allExportsFlow, importsFlowRequire
85
+ const reactFolder = /** @type {string | undefined} */ (
86
+ context.settings.eXtraJSX?.reactFolder
87
+ );
88
+ const rootPath = /** @type {string | undefined} */ (
89
+ context.settings.eXtraJSX?.rootPath
90
+ );
91
+ console.debug("reactFolder is:", reactFolder);
92
+ console.debug("rootPath is:", rootPath);
93
+
94
+ if (!reactFolder || !rootPath) return {};
95
+ // make the resolver by resolving the TypeScript from the rootPath (getTsConfigPaths, makeAbsoluteFromTsConfigPaths, makeResolverFromAbsoluteTsConfigPaths)
96
+ // pass the resolver to importsFlow, allExportsFlow, importsFlowRequire (resolver.resolveFileSync, getCommentedDirectiveFromModule)
97
+
98
+ const tsConfigPaths = getTsConfigPaths(rootPath);
99
+ const absoluteTsConfigPaths = makeAbsoluteFromTsConfigPaths(tsConfigPaths);
100
+ const resolver = makeResolverFromAbsoluteTsConfigPaths(
101
+ absoluteTsConfigPaths,
102
+ );
103
+ console.debug("resolver is:", resolver);
83
104
 
84
105
  if (result.skip) return {};
85
106
  const { verifiedCommentedDirective } = result; // Leave untouched. Since this is the verifying process. Commented directives from imported modules however, don't need to be further verified, and can simply be obtained by the flat module index.
@@ -108,4 +129,37 @@ In this context, {{ ${specificFailure} }} `,
108
129
  },
109
130
  };
110
131
 
132
+ const getTsConfigPaths = (rootPath) => {
133
+ const parsed = ts.getParsedCommandLineOfConfigFile(
134
+ path.join(rootPath, "tsconfig.json"),
135
+ {},
136
+ ts.sys,
137
+ );
138
+
139
+ if (!parsed) return {};
140
+
141
+ const paths = parsed.options.paths ?? {};
142
+ return paths;
143
+ };
144
+
145
+ const makeAbsoluteFromTsConfigPaths = (rootPath, tsConfigPaths) => {
146
+ /** @type {Record<string, string[]>} */
147
+ const results = {};
148
+
149
+ for (const [alias, targets] of Object.entries(tsConfigPaths)) {
150
+ results[alias] = targets.map((p) =>
151
+ path.resolve(rootPath, p.replace(/^\.\//, "")),
152
+ );
153
+ }
154
+
155
+ return results;
156
+ };
157
+
158
+ const makeResolverFromAbsoluteTsConfigPaths = (absoluteTsConfigPaths) =>
159
+ new ResolverFactory({
160
+ extensions: EXTENSIONS,
161
+ alias: absoluteTsConfigPaths,
162
+ modules: [], // voluntarily ignoring "node_modules"
163
+ });
164
+
111
165
  export default rule; // enforce-commented-directives-import-rules
@@ -11,9 +11,9 @@
11
11
  import { walkAST } from "../../../_commons/utilities/walk-ast.js";
12
12
 
13
13
  /**
14
- * Analyzes a source code's exports to detect re-exports.
15
- * @param {SourceCode} sourceCode The `SourceCode` to analyze.
16
- * @returns An object with the `reExportsWithSource` key tracking the direct re-exports from an imported source in an array and the `reExportsViaLocal` key tracking the indirect re-exports from an imported source in an array.
14
+ * $COMMENT#JSDOC#DEFINITIONS#ANALYZEEXPORTSFORREEXPORTS
15
+ * @param {SourceCode} sourceCode $COMMENT#JSDOC#PARAMS#SOURCECODEB
16
+ * @returns $COMMENT#JSDOC#RETURNS#ANALYZEEXPORTSFORREEXPORTS
17
17
  */
18
18
  export const analyzeExportsForReExports = (sourceCode) => {
19
19
  /** @type {Map<string, {source: string, importNode: ImportDeclaration}>} */