### Install bun-plugin-glob-import Source: https://github.com/ttempaa/bun-plugin-glob-import/blob/main/README.md Command to install the plugin as a development dependency using Bun. ```sh bun add -d bun-plugin-glob-import ``` -------------------------------- ### Runtime/Bundler Glob Import Example Source: https://github.com/ttempaa/bun-plugin-glob-import/blob/main/README.md Shows how to import modules using glob patterns, supported by both runtime and bundler plugin usage. ```ts // Supported for both runtime and bundler plugin usage const { default: commands } = await import('./commands/**/*.ts'); console.log(commands); /* => [ { default: [Function: update] }, { default: [Function: get] }, { default: [Function: create] }, { default: [Function: delete] }, { default: [Function: list] }, { default: [Function: ping] }, ] */ ``` -------------------------------- ### Bundler Glob Import Example Source: https://github.com/ttempaa/bun-plugin-glob-import/blob/main/README.md Demonstrates importing modules using glob patterns when the plugin is used as a bundler plugin. ```ts // Only supported when using as a bundler plugin import commands from './commands/**/*.ts'; console.log(commands); ``` -------------------------------- ### Use as Bundler Plugin Source: https://github.com/ttempaa/bun-plugin-glob-import/blob/main/README.md Example of integrating the glob import plugin into Bun's build process. ```ts import { globImportPlugin } from 'bun-plugin-glob-import'; await Bun.build({ plugins: [globImportPlugin()], }); ``` -------------------------------- ### Use as Runtime Plugin Source: https://github.com/ttempaa/bun-plugin-glob-import/blob/main/README.md Configuration for using the plugin at runtime via bunfig.toml. ```toml preload = [ "bun-plugin-glob-import/register" ] ``` -------------------------------- ### TypeScript Type Definitions Source: https://github.com/ttempaa/bun-plugin-glob-import/blob/main/README.md Configuration for tsconfig.json to enable glob import type checking. ```json { "compilerOptions": { "types": ["bun-plugin-glob-import/types"] } } ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.