Skip to content

Commit fdfafeb

Browse files
committed
style: reformat source code
1 parent d1199bd commit fdfafeb

File tree

11 files changed

+49
-49
lines changed

11 files changed

+49
-49
lines changed

src/debug.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ import { debuglog } from 'node:util'
1212
/**
1313
* Debug logger instance configured for AdonisJS application debugging.
1414
* Uses Node.js built-in debuglog with the 'adonisjs:app' namespace.
15-
*
15+
*
1616
* Enable debug output by setting NODE_DEBUG=adonisjs:app environment variable.
17-
*
17+
*
1818
* @example
1919
* debug('Application state changed to: %s', newState)
2020
*/

src/directories.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ import type { DirectoriesNode } from './types.ts'
1313
* Default directory structure for AdonisJS applications.
1414
* These paths are relative to the application root and define
1515
* the conventional locations for different types of files.
16-
*
16+
*
1717
* Applications can override these defaults in their adonisrc.js file.
18-
*
18+
*
1919
* @example
2020
* // In adonisrc.js
2121
* export default defineConfig({

src/feature_flags.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,27 +10,27 @@
1010
/**
1111
* A light weight implementation of feature flags to conditionally enable
1212
* experimental and legacy features.
13-
*
13+
*
1414
* @template FlagsList - Type definition for the feature flags object
15-
*
15+
*
1616
* @example
1717
* const flags = new FeatureFlags({ newUI: true, betaFeature: false })
1818
* if (flags.enabled('newUI')) {
1919
* // Enable new UI
2020
* }
21-
*
21+
*
2222
* @example
2323
* const dynamicFlags = new FeatureFlags(() => getConfigFlags())
24-
* flags.when('betaFeature',
25-
* () => console.log('Beta enabled'),
24+
* flags.when('betaFeature',
25+
* () => console.log('Beta enabled'),
2626
* () => console.log('Beta disabled')
2727
* )
2828
*/
2929
export class FeatureFlags<FlagsList extends Record<any, any>> {
3030
/**
3131
* Static flags object containing feature flag values.
3232
* Used when flags are provided as a static object during construction.
33-
*
33+
*
3434
* @private
3535
* @type {FlagsList | undefined}
3636
*/
@@ -39,7 +39,7 @@ export class FeatureFlags<FlagsList extends Record<any, any>> {
3939
/**
4040
* Factory function to generate flags dynamically.
4141
* Used when flags need to be computed at runtime.
42-
*
42+
*
4343
* @private
4444
* @type {(() => FlagsList) | undefined}
4545
*/

src/managers/config.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,15 @@ import debug from '../debug.ts'
1414
* ConfigManager handles loading, parsing, and managing application configuration.
1515
* It can load configuration from file system directories or use explicitly
1616
* provided configuration objects (useful for testing).
17-
*
17+
*
1818
* The manager creates a Config instance that provides type-safe access to
1919
* configuration values throughout the application.
20-
*
20+
*
2121
* @example
2222
* const manager = new ConfigManager(new URL('file:///app/'))
2323
* await manager.process('config')
2424
* const dbConfig = manager.config.get('database')
25-
*
25+
*
2626
* @example
2727
* // Using explicit config for testing
2828
* const manager = new ConfigManager(appRoot)
@@ -32,7 +32,7 @@ import debug from '../debug.ts'
3232
export class ConfigManager {
3333
/**
3434
* The application root directory URL used to resolve the config directory path.
35-
*
35+
*
3636
* @private
3737
* @type {URL}
3838
*/
@@ -41,7 +41,7 @@ export class ConfigManager {
4141
/**
4242
* Configuration values set explicitly via useConfig() method.
4343
* When provided, prevents loading config files from the file system.
44-
*
44+
*
4545
* @private
4646
* @type {Record<any, any> | undefined}
4747
*/
@@ -50,7 +50,7 @@ export class ConfigManager {
5050
/**
5151
* Reference to the Config instance that provides access to
5252
* all configuration values. Available after process() method has been called.
53-
*
53+
*
5454
* @type {Config}
5555
*/
5656
config!: Config

src/managers/node_env.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ const DEV_ENVS = ['dev', 'develop', 'development']
3030
* - The "prod" and "production" envs are normalized to "production"
3131
* - The "dev", "develop", and "development" envs are normalized to "development"
3232
* - Unknown or invalid environments remain as-is
33-
*
33+
*
3434
* @example
3535
* const manager = new NodeEnvManager()
3636
* manager.process()
@@ -39,15 +39,15 @@ const DEV_ENVS = ['dev', 'develop', 'development']
3939
export class NodeEnvManager {
4040
/**
4141
* The normalized node environment value. Defaults to 'unknown' until process() is called.
42-
*
42+
*
4343
* @type {'unknown' | 'development' | 'production' | 'test' | string}
4444
* @default 'unknown'
4545
*/
4646
nodeEnvironment: 'unknown' | 'development' | 'production' | 'test' | string = 'unknown'
4747

4848
/**
4949
* Normalizes the NODE_ENV value to standard environment names.
50-
*
50+
*
5151
* @private
5252
* @param {string} [env] - The environment string to normalize
5353
* @returns {string} The normalized environment string

src/managers/preloads.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import type { AppEnvironments, PreloadNode } from '../types.ts'
1717
*
1818
* The class relies on "import.meta.resolve" to resolve the provider modules from
1919
* the root of the application.
20-
*
20+
*
2121
* @example
2222
* const manager = new PreloadsManager({ environment: 'web' })
2323
* manager.use([{ file: () => import('./preloads/routes'), environment: ['web'] }])
@@ -27,7 +27,7 @@ export class PreloadsManager {
2727
/**
2828
* List of registered preload modules to be imported.
2929
* Each preload node contains the import function and environment restrictions.
30-
*
30+
*
3131
* @private
3232
* @type {PreloadNode[]}
3333
* @default []
@@ -37,7 +37,7 @@ export class PreloadsManager {
3737
/**
3838
* Configuration options for the preloads manager.
3939
* Contains the current application environment used for filtering preloads.
40-
*
40+
*
4141
* @private
4242
* @type {Object}
4343
* @property {AppEnvironments} environment - The current application environment

src/managers/providers.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,17 @@ import {
2222
/**
2323
* ProvidersManager handles the complete lifecycle of service providers in an AdonisJS application.
2424
* It manages provider registration, booting, starting, readying, and shutdown phases.
25-
*
25+
*
2626
* Service providers are classes that register services, bind dependencies, and set up
2727
* application components during different phases of the application lifecycle.
28-
*
28+
*
2929
* Lifecycle phases:
3030
* 1. **Register**: Bind services to the IoC container
3131
* 2. **Boot**: Initialize services after all providers are registered
3232
* 3. **Start**: Start services (e.g., HTTP server, background jobs)
3333
* 4. **Ready**: Notify services that application is ready to serve requests
3434
* 5. **Shutdown**: Gracefully shutdown services during app termination
35-
*
35+
*
3636
* @example
3737
* const manager = new ProvidersManager({ environment: 'web', providersState: [app] })
3838
* manager.use([
@@ -47,7 +47,7 @@ export class ProvidersManager {
4747
/**
4848
* Array of instantiated provider instances used throughout the application lifecycle.
4949
* These instances are created during the register phase and reused for all subsequent phases.
50-
*
50+
*
5151
* @private
5252
* @type {ContainerProviderContract[]}
5353
* @default []
@@ -58,7 +58,7 @@ export class ProvidersManager {
5858
* Array of provider instances that implement the shutdown lifecycle method.
5959
* Kept separately to enable efficient shutdown processing without scanning all providers.
6060
* These providers are called during application termination for cleanup.
61-
*
61+
*
6262
* @private
6363
* @type {ContainerProviderContract[]}
6464
* @default []
@@ -69,7 +69,7 @@ export class ProvidersManager {
6969
* Array of provider nodes from the adonisrc.js configuration.
7070
* Each node contains the import function and environment restrictions.
7171
* Cleared after providers are resolved and instantiated.
72-
*
72+
*
7373
* @private
7474
* @type {ProviderNode[]}
7575
* @default []
@@ -78,7 +78,7 @@ export class ProvidersManager {
7878

7979
/**
8080
* Configuration options for the providers manager.
81-
*
81+
*
8282
* @private
8383
* @type {Object}
8484
* @property {AppEnvironments} environment - Current application environment for filtering providers

src/managers/rc_file.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ import { RcFileParser } from '../rc_file/parser.ts'
1515
* RcFileManager handles loading, parsing, and processing of the AdonisJS
1616
* configuration file (adonisrc.js). This file contains application metadata,
1717
* directory mappings, providers, preloads, and other configuration.
18-
*
18+
*
1919
* The manager can work with:
2020
* - adonisrc.js file from disk
2121
* - Explicitly provided RC contents (useful for testing)
22-
*
22+
*
2323
* @example
2424
* const manager = new RcFileManager(new URL('file:///app/'))
2525
* await manager.process()
@@ -28,7 +28,7 @@ import { RcFileParser } from '../rc_file/parser.ts'
2828
export class RcFileManager {
2929
/**
3030
* The application root directory URL used to resolve the adonisrc.js file path.
31-
*
31+
*
3232
* @private
3333
* @type {URL}
3434
*/
@@ -37,7 +37,7 @@ export class RcFileManager {
3737
/**
3838
* RC file contents set explicitly via rcContents() method.
3939
* When set, prevents loading adonisrc.js from disk.
40-
*
40+
*
4141
* @private
4242
* @type {Record<string, any> | undefined}
4343
*/
@@ -46,7 +46,7 @@ export class RcFileManager {
4646
/**
4747
* Reference to the parsed and validated RC file configuration.
4848
* Available after the process() method has been called successfully.
49-
*
49+
*
5050
* @type {RcFile}
5151
*/
5252
rcFile!: RcFile

src/rc_file/parser.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,14 +41,14 @@ const KNOWN_ASSEMBLER_HOOKS: (keyof NonNullable<RcFile['hooks']>)[] = [
4141
* RcFileParser processes and validates the adonisrc.js configuration file.
4242
* It merges user configuration with defaults, applies presets, validates structure,
4343
* and transforms the configuration into a normalized format.
44-
*
44+
*
4545
* The parser handles:
4646
* - Merging user config with framework defaults
4747
* - Applying configuration presets
4848
* - Validating providers, preloads, and hooks
4949
* - Normalizing directory paths
5050
* - Processing environment-specific configurations
51-
*
51+
*
5252
* @example
5353
* const parser = new RcFileParser({
5454
* typescript: true,
@@ -92,7 +92,7 @@ export class RcFileParser {
9292
/**
9393
* Reference to the original raw configuration object before processing.
9494
* Preserved for debugging and error reporting purposes.
95-
*
95+
*
9696
* @private
9797
* @type {Record<string, any>}
9898
*/

src/stubs/manager.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@ import { readFileFromSources } from '../utils.ts'
2020
/**
2121
* StubsManager handles reading, copying, and building stubs from various sources.
2222
* Stubs are template files used for code generation in AdonisJS applications.
23-
*
23+
*
2424
* The manager can source stubs from:
2525
* - Application's local stubs directory (publishTarget)
2626
* - Custom file system paths
2727
* - Package exports with stubsRoot
28-
*
28+
*
2929
* @example
3030
* const stubsManager = new StubsManager(app, '/path/to/stubs')
3131
* const stub = await stubsManager.build('controller.stub')
@@ -35,7 +35,7 @@ export class StubsManager {
3535
/**
3636
* Reference to the application instance for importing packages
3737
* and accessing application context.
38-
*
38+
*
3939
* @private
4040
* @type {Application<any>}
4141
*/
@@ -45,7 +45,7 @@ export class StubsManager {
4545
* Absolute path to the directory where stubs should be published
4646
* or read from with highest priority. This is typically the
4747
* application's stubs directory.
48-
*
48+
*
4949
* @private
5050
* @type {string}
5151
*/

0 commit comments

Comments
 (0)