@bamboocss/config
Advanced tools
+6
-6
| { | ||
| "name": "@bamboocss/config", | ||
| "version": "1.12.0", | ||
| "version": "1.12.1", | ||
| "description": "Find and load bamboo config", | ||
@@ -67,7 +67,7 @@ "homepage": "https://bamboo-css.com", | ||
| "typescript": "6.0.2", | ||
| "@bamboocss/logger": "1.12.0", | ||
| "@bamboocss/preset-bamboo": "1.12.0", | ||
| "@bamboocss/preset-base": "1.12.0", | ||
| "@bamboocss/shared": "1.12.0", | ||
| "@bamboocss/types": "1.12.0" | ||
| "@bamboocss/logger": "1.12.1", | ||
| "@bamboocss/preset-bamboo": "1.12.1", | ||
| "@bamboocss/shared": "1.12.1", | ||
| "@bamboocss/preset-base": "1.12.1", | ||
| "@bamboocss/types": "1.12.1" | ||
| }, | ||
@@ -74,0 +74,0 @@ "devDependencies": { |
| import { Config, DiffConfigResult } from "@bamboocss/types"; | ||
| //#region src/diff-config.d.ts | ||
| type ConfigOrFn = Config | (() => Config); | ||
| /** | ||
| * Diff the two config objects and return the list of affected properties | ||
| */ | ||
| declare function diffConfigs(config: ConfigOrFn, prevConfig: Config | undefined): DiffConfigResult; | ||
| //#endregion | ||
| export { diffConfigs }; |
| import { Config, DiffConfigResult } from "@bamboocss/types"; | ||
| //#region src/diff-config.d.ts | ||
| type ConfigOrFn = Config | (() => Config); | ||
| /** | ||
| * Diff the two config objects and return the list of affected properties | ||
| */ | ||
| declare function diffConfigs(config: ConfigOrFn, prevConfig: Config | undefined): DiffConfigResult; | ||
| //#endregion | ||
| export { diffConfigs }; |
-111
| import { BambooHooks as BambooHooks$1, BambooPlugin, Config, ConfigTsOptions, DiffConfigResult, LoadConfigResult as LoadConfigResult$1 } from "@bamboocss/types"; | ||
| import { CompilerOptions, TypeAcquisition } from "typescript"; | ||
| //#region src/types.d.ts | ||
| interface ConfigFileOptions { | ||
| cwd: string; | ||
| file?: string; | ||
| } | ||
| interface BundleConfigResult<T = Config> { | ||
| config: T; | ||
| dependencies: string[]; | ||
| path: string; | ||
| } | ||
| //#endregion | ||
| //#region src/bundle-config.d.ts | ||
| declare function bundleConfig(options: ConfigFileOptions): Promise<BundleConfigResult>; | ||
| //#endregion | ||
| //#region src/diff-config.d.ts | ||
| type ConfigOrFn = Config | (() => Config); | ||
| /** | ||
| * Diff the two config objects and return the list of affected properties | ||
| */ | ||
| declare function diffConfigs(config: ConfigOrFn, prevConfig: Config | undefined): DiffConfigResult; | ||
| //#endregion | ||
| //#region src/find-config.d.ts | ||
| declare function findConfig(options: Partial<ConfigFileOptions>): string; | ||
| //#endregion | ||
| //#region ../../node_modules/.pnpm/pkg-types@2.3.0/node_modules/pkg-types/dist/index.d.mts | ||
| type StripEnums<T extends Record<string, any>> = { [K in keyof T]: T[K] extends boolean ? T[K] : T[K] extends string ? T[K] : T[K] extends object ? T[K] : T[K] extends Array<any> ? T[K] : T[K] extends undefined ? undefined : any }; | ||
| interface TSConfig { | ||
| compilerOptions?: StripEnums<CompilerOptions>; | ||
| exclude?: string[]; | ||
| compileOnSave?: boolean; | ||
| extends?: string | string[]; | ||
| files?: string[]; | ||
| include?: string[]; | ||
| typeAcquisition?: TypeAcquisition; | ||
| references?: { | ||
| path: string; | ||
| }[]; | ||
| } | ||
| /** | ||
| * Defines a TSConfig structure. | ||
| * @param tsconfig - The contents of `tsconfig.json` as an object. See {@link TSConfig}. | ||
| * @returns the same `tsconfig.json` object. | ||
| */ | ||
| //#endregion | ||
| //#region src/ts-config-paths.d.ts | ||
| interface PathMapping { | ||
| pattern: RegExp; | ||
| paths: string[]; | ||
| } | ||
| /** | ||
| * @see https://github.com/aleclarson/vite-tsconfig-paths/blob/e8f0acf7adfcfbf77edbe937f64b4e5d39557ad0/src/mappings.ts | ||
| */ | ||
| declare function convertTsPathsToRegexes(paths: Record<string, string[]>, baseUrl: string): PathMapping[]; | ||
| //#endregion | ||
| //#region src/get-mod-deps.d.ts | ||
| interface GetDepsOptions { | ||
| filename: string; | ||
| ext: string; | ||
| cwd: string; | ||
| seen: Set<string>; | ||
| baseUrl: string | undefined; | ||
| pathMappings: PathMapping[]; | ||
| foundModuleAliases: Map<string, string>; | ||
| compilerOptions?: TSConfig['compilerOptions']; | ||
| } | ||
| declare function getConfigDependencies(filePath: string, tsOptions?: ConfigTsOptions, compilerOptions?: TSConfig['compilerOptions']): { | ||
| deps: Set<string>; | ||
| aliases: Map<string, string>; | ||
| }; | ||
| //#endregion | ||
| //#region src/get-resolved-config.d.ts | ||
| type Extendable$1<T> = T & { | ||
| extend?: T; | ||
| }; | ||
| type ExtendableConfig$1 = Extendable$1<Config>; | ||
| /** | ||
| * Recursively merge all presets into a single config (depth-first using stack) | ||
| */ | ||
| declare function getResolvedConfig(config: ExtendableConfig$1, cwd: string, hooks?: Partial<BambooHooks$1>): Promise<Config>; | ||
| //#endregion | ||
| //#region src/load-config.d.ts | ||
| /** | ||
| * Find, load and resolve the final config (including presets) | ||
| */ | ||
| declare function loadConfig(options: ConfigFileOptions): Promise<LoadConfigResult>; | ||
| //#endregion | ||
| //#region src/resolve-config.d.ts | ||
| /** | ||
| * Resolve the final config (including presets) | ||
| * @bamboocss/preset-base: ALWAYS included if NOT using eject: true | ||
| * @bamboocss/preset-bamboo: only included by default if no presets | ||
| */ | ||
| declare function resolveConfig(result: BundleConfigResult, cwd: string): Promise<LoadConfigResult$1>; | ||
| //#endregion | ||
| //#region src/merge-hooks.d.ts | ||
| declare const mergeHooks: (plugins: BambooPlugin[]) => BambooHooks; | ||
| //#endregion | ||
| //#region src/merge-config.d.ts | ||
| type Extendable<T> = T & { | ||
| extend?: T; | ||
| }; | ||
| type ExtendableConfig = Extendable<Config>; | ||
| /** | ||
| * Merge all configs into a single config | ||
| */ | ||
| declare function mergeConfigs(configs: ExtendableConfig[]): any; | ||
| //#endregion | ||
| export { type BundleConfigResult, type GetDepsOptions, bundleConfig, convertTsPathsToRegexes, diffConfigs, findConfig, getConfigDependencies, getResolvedConfig, loadConfig, mergeConfigs, mergeHooks, resolveConfig }; |
-111
| import { CompilerOptions, TypeAcquisition } from "typescript"; | ||
| import { BambooHooks as BambooHooks$1, BambooPlugin, Config, ConfigTsOptions, DiffConfigResult, LoadConfigResult as LoadConfigResult$1 } from "@bamboocss/types"; | ||
| //#region src/types.d.ts | ||
| interface ConfigFileOptions { | ||
| cwd: string; | ||
| file?: string; | ||
| } | ||
| interface BundleConfigResult<T = Config> { | ||
| config: T; | ||
| dependencies: string[]; | ||
| path: string; | ||
| } | ||
| //#endregion | ||
| //#region src/bundle-config.d.ts | ||
| declare function bundleConfig(options: ConfigFileOptions): Promise<BundleConfigResult>; | ||
| //#endregion | ||
| //#region src/diff-config.d.ts | ||
| type ConfigOrFn = Config | (() => Config); | ||
| /** | ||
| * Diff the two config objects and return the list of affected properties | ||
| */ | ||
| declare function diffConfigs(config: ConfigOrFn, prevConfig: Config | undefined): DiffConfigResult; | ||
| //#endregion | ||
| //#region src/find-config.d.ts | ||
| declare function findConfig(options: Partial<ConfigFileOptions>): string; | ||
| //#endregion | ||
| //#region ../../node_modules/.pnpm/pkg-types@2.3.0/node_modules/pkg-types/dist/index.d.mts | ||
| type StripEnums<T extends Record<string, any>> = { [K in keyof T]: T[K] extends boolean ? T[K] : T[K] extends string ? T[K] : T[K] extends object ? T[K] : T[K] extends Array<any> ? T[K] : T[K] extends undefined ? undefined : any }; | ||
| interface TSConfig { | ||
| compilerOptions?: StripEnums<CompilerOptions>; | ||
| exclude?: string[]; | ||
| compileOnSave?: boolean; | ||
| extends?: string | string[]; | ||
| files?: string[]; | ||
| include?: string[]; | ||
| typeAcquisition?: TypeAcquisition; | ||
| references?: { | ||
| path: string; | ||
| }[]; | ||
| } | ||
| /** | ||
| * Defines a TSConfig structure. | ||
| * @param tsconfig - The contents of `tsconfig.json` as an object. See {@link TSConfig}. | ||
| * @returns the same `tsconfig.json` object. | ||
| */ | ||
| //#endregion | ||
| //#region src/ts-config-paths.d.ts | ||
| interface PathMapping { | ||
| pattern: RegExp; | ||
| paths: string[]; | ||
| } | ||
| /** | ||
| * @see https://github.com/aleclarson/vite-tsconfig-paths/blob/e8f0acf7adfcfbf77edbe937f64b4e5d39557ad0/src/mappings.ts | ||
| */ | ||
| declare function convertTsPathsToRegexes(paths: Record<string, string[]>, baseUrl: string): PathMapping[]; | ||
| //#endregion | ||
| //#region src/get-mod-deps.d.ts | ||
| interface GetDepsOptions { | ||
| filename: string; | ||
| ext: string; | ||
| cwd: string; | ||
| seen: Set<string>; | ||
| baseUrl: string | undefined; | ||
| pathMappings: PathMapping[]; | ||
| foundModuleAliases: Map<string, string>; | ||
| compilerOptions?: TSConfig['compilerOptions']; | ||
| } | ||
| declare function getConfigDependencies(filePath: string, tsOptions?: ConfigTsOptions, compilerOptions?: TSConfig['compilerOptions']): { | ||
| deps: Set<string>; | ||
| aliases: Map<string, string>; | ||
| }; | ||
| //#endregion | ||
| //#region src/get-resolved-config.d.ts | ||
| type Extendable$1<T> = T & { | ||
| extend?: T; | ||
| }; | ||
| type ExtendableConfig$1 = Extendable$1<Config>; | ||
| /** | ||
| * Recursively merge all presets into a single config (depth-first using stack) | ||
| */ | ||
| declare function getResolvedConfig(config: ExtendableConfig$1, cwd: string, hooks?: Partial<BambooHooks$1>): Promise<Config>; | ||
| //#endregion | ||
| //#region src/load-config.d.ts | ||
| /** | ||
| * Find, load and resolve the final config (including presets) | ||
| */ | ||
| declare function loadConfig(options: ConfigFileOptions): Promise<LoadConfigResult>; | ||
| //#endregion | ||
| //#region src/resolve-config.d.ts | ||
| /** | ||
| * Resolve the final config (including presets) | ||
| * @bamboocss/preset-base: ALWAYS included if NOT using eject: true | ||
| * @bamboocss/preset-bamboo: only included by default if no presets | ||
| */ | ||
| declare function resolveConfig(result: BundleConfigResult, cwd: string): Promise<LoadConfigResult$1>; | ||
| //#endregion | ||
| //#region src/merge-hooks.d.ts | ||
| declare const mergeHooks: (plugins: BambooPlugin[]) => BambooHooks; | ||
| //#endregion | ||
| //#region src/merge-config.d.ts | ||
| type Extendable<T> = T & { | ||
| extend?: T; | ||
| }; | ||
| type ExtendableConfig = Extendable<Config>; | ||
| /** | ||
| * Merge all configs into a single config | ||
| */ | ||
| declare function mergeConfigs(configs: ExtendableConfig[]): any; | ||
| //#endregion | ||
| export { type BundleConfigResult, type GetDepsOptions, bundleConfig, convertTsPathsToRegexes, diffConfigs, findConfig, getConfigDependencies, getResolvedConfig, loadConfig, mergeConfigs, mergeHooks, resolveConfig }; |
| import { BambooPlugin, Config } from "@bamboocss/types"; | ||
| //#region src/merge-hooks.d.ts | ||
| declare const mergeHooks: (plugins: BambooPlugin[]) => BambooHooks; | ||
| //#endregion | ||
| //#region src/merge-config.d.ts | ||
| type Extendable<T> = T & { | ||
| extend?: T; | ||
| }; | ||
| type ExtendableConfig = Extendable<Config>; | ||
| /** | ||
| * Merge all configs into a single config | ||
| */ | ||
| declare function mergeConfigs(configs: ExtendableConfig[]): any; | ||
| //#endregion | ||
| export { mergeConfigs, mergeHooks }; |
| import { BambooPlugin, Config } from "@bamboocss/types"; | ||
| //#region src/merge-hooks.d.ts | ||
| declare const mergeHooks: (plugins: BambooPlugin[]) => BambooHooks; | ||
| //#endregion | ||
| //#region src/merge-config.d.ts | ||
| type Extendable<T> = T & { | ||
| extend?: T; | ||
| }; | ||
| type ExtendableConfig = Extendable<Config>; | ||
| /** | ||
| * Merge all configs into a single config | ||
| */ | ||
| declare function mergeConfigs(configs: ExtendableConfig[]): any; | ||
| //#endregion | ||
| export { mergeConfigs, mergeHooks }; |
| //#region src/ts-config-paths.d.ts | ||
| interface PathMapping { | ||
| pattern: RegExp; | ||
| paths: string[]; | ||
| } | ||
| //#endregion | ||
| //#region src/resolve-ts-path-pattern.d.ts | ||
| /** | ||
| * @see https://github.com/aleclarson/vite-tsconfig-paths/blob/e8f0acf7adfcfbf77edbe937f64b4e5d39557ad0/src/index.ts#LL231C57-L231C57 | ||
| */ | ||
| declare const resolveTsPathPattern: (pathMappings: PathMapping[], moduleSpecifier: string) => string | undefined; | ||
| //#endregion | ||
| export { resolveTsPathPattern }; |
| //#region src/ts-config-paths.d.ts | ||
| interface PathMapping { | ||
| pattern: RegExp; | ||
| paths: string[]; | ||
| } | ||
| //#endregion | ||
| //#region src/resolve-ts-path-pattern.d.ts | ||
| /** | ||
| * @see https://github.com/aleclarson/vite-tsconfig-paths/blob/e8f0acf7adfcfbf77edbe937f64b4e5d39557ad0/src/index.ts#LL231C57-L231C57 | ||
| */ | ||
| declare const resolveTsPathPattern: (pathMappings: PathMapping[], moduleSpecifier: string) => string | undefined; | ||
| //#endregion | ||
| export { resolveTsPathPattern }; |
AI-detected potential code anomaly
Supply chain riskAI has identified unusual behaviors that may pose a security risk.
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
AI-detected potential code anomaly
Supply chain riskAI has identified unusual behaviors that may pose a security risk.
0
-100%96426
-9.92%10
-44.44%+ Added
+ Added
+ Added
+ Added
+ Added
- Removed
- Removed
- Removed
- Removed
- Removed
Updated
Updated
Updated