laravel-type-bridge-developmentlisted
Install: claude install-skill diegosouzapw/awesome-omni-skill
# Laravel Type Bridge Development
## When to use this skill
Use this skill when:
- Generating TypeScript or JavaScript enums from PHP backed enums
- Generating frontend i18n translation files from Laravel lang files
- Generating enum translator composables for frontend use
- Interacting with or integrating the generated enums/translations/translator composables in frontend code
- Configuring or extending the type bridge generation pipeline
## Installation & Setup
```bash
composer require gaiatools/laravel-type-bridge
php artisan type-bridge:publish
# Alternative:
# php artisan vendor:publish --tag=type-bridge-config
```
This publishes `config/type-bridge.php` where all generation is configured.
## Configuration (`config/type-bridge.php`)
```php
return [
'output_format' => 'ts', // 'ts' | 'js'
'max_line_length' => 120, // ESLint disable-line threshold (0 to disable)
'trailing_commas' => true,
'i18n_library' => 'i18next', // 'i18next' | 'vue-i18n'
'enums' => [
'generate_backed_enums' => true,
'discovery' => [
'include_paths' => [app_path('Enums')],
'exclude_paths' => [],
],
'output_path' => 'js/enums/generated', // relative to resources/
'import_base' => '@/enums/generated',
],
'translations' => [
'discovery' => [
'include_paths' => [base_path('lang')],
'exclude_paths' => [],
],
'output_path' => 'js/lang/ge