PHPackages                             myhayo/laravel-filament-json-field - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. myhayo/laravel-filament-json-field

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

myhayo/laravel-filament-json-field
==================================

A Laravel Filament JSON Field integration with CodeMirror support

v12.0.1(1mo ago)02↓90%MITPHPPHP 8.2.\*|8.3.\*|8.4.\*

Since Jun 4Pushed 1mo agoCompare

[ Source](https://github.com/myhayo/laravel-filament-json-field)[ Packagist](https://packagist.org/packages/myhayo/laravel-filament-json-field)[ Docs](https://github.com/codebar-ag/laravel-filament-json-field)[ RSS](/packages/myhayo-laravel-filament-json-field/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (1)Dependencies (14)Versions (2)Used By (0)

[![](https://camo.githubusercontent.com/f1079972c8d694b1c8adc41d5125bf926972a25c1745759b6bbbf58a771a4177/68747470733a2f2f62616e6e6572732e6265796f6e64636f2e64652f4c61726176656c25323046696c616d656e742532304a736f6e2532304669656c642e706e673f7468656d653d6c69676874267061636b6167654d616e616765723d636f6d706f7365722b72657175697265267061636b6167654e616d653d636f64656261722d61672532466c61726176656c2d66696c616d656e742d6a736f6e2d6669656c64267061747465726e3d63697263756974426f617264267374796c653d7374796c655f31266465736372697074696f6e3d412b4c61726176656c2b46696c616d656e742b4a736f6e2b4669656c642b696e746567726174696f6e2e266d643d312673686f7757617465726d61726b3d3126666f6e7453697a653d313030707826696d616765733d6c696768742d62756c62)](https://camo.githubusercontent.com/f1079972c8d694b1c8adc41d5125bf926972a25c1745759b6bbbf58a771a4177/68747470733a2f2f62616e6e6572732e6265796f6e64636f2e64652f4c61726176656c25323046696c616d656e742532304a736f6e2532304669656c642e706e673f7468656d653d6c69676874267061636b6167654d616e616765723d636f6d706f7365722b72657175697265267061636b6167654e616d653d636f64656261722d61672532466c61726176656c2d66696c616d656e742d6a736f6e2d6669656c64267061747465726e3d63697263756974426f617264267374796c653d7374796c655f31266465736372697074696f6e3d412b4c61726176656c2b46696c616d656e742b4a736f6e2b4669656c642b696e746567726174696f6e2e266d643d312673686f7757617465726d61726b3d3126666f6e7453697a653d313030707826696d616765733d6c696768742d62756c62)

[![Latest Version on Packagist](https://camo.githubusercontent.com/47819c6909b919105f1beeb5d884000cb73f8e0b384a87cd4c49ea56c917355b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f636f64656261722d61672f6c61726176656c2d66696c616d656e742d6a736f6e2d6669656c642e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/codebar-ag/laravel-filament-json-field)[![GitHub-Tests](https://github.com/codebar-ag/laravel-filament-json-field/actions/workflows/run-tests.yml/badge.svg?branch=main)](https://github.com/codebar-ag/laravel-filament-json-field/actions/workflows/run-tests.yml)[![GitHub Code Style](https://github.com/codebar-ag/laravel-filament-json-field/actions/workflows/fix-php-code-style-issues.yml/badge.svg?branch=main)](https://github.com/codebar-ag/laravel-filament-json-field/actions/workflows/fix-php-code-style-issues.yml)[![Total Downloads](https://camo.githubusercontent.com/501e2af77f916671fc017138fd7a784a3b204b3abee19003a6ee147596a211b2/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f636f64656261722d61672f6c61726176656c2d66696c616d656e742d6a736f6e2d6669656c642e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/codebar-ag/laravel-filament-json-field)

💡 What is Filament Json Field?
------------------------------

[](#-what-is-filament-json-field)

Filament Json Field is a Laravel Filament JSON Field integration with CodeMirror support, providing a powerful and feature-rich JSON editor for your Filament forms and infolists.

🛠 Requirements
--------------

[](#-requirements)

PackagePHPLaravelFilament FormsFilament InfolistsFilament Supportv13.0 (alpha)^8.3, ^8.4^13.0^4.0^4.0^4.0v12.0^8.2, ^8.3, ^8.4^12.0^3.3^3.3^3.3v2.0^8.1^11.0^3.2^3.2^3.2v1.0^8.1^10.45, ^11.0^3.2^3.2^3.2⚙️ Installation
---------------

[](#️-installation)

You can install the package via composer:

```
composer require codebar-ag/laravel-filament-json-field
php artisan filament:assets
```

Usage
-----

[](#usage)

### Forms

[](#forms)

```
use CodebarAg\FilamentJsonField\Forms\Components\JsonInput;

...

public function form(Form $form): Form
{
    return $form
        ->schema([
            JsonInput::make('json')
                ->label('JSON Data')
                ->lineNumbers(true)
                ->lineWrapping(true)
                ->autoCloseBrackets(true)
                ->darkTheme(true)
                ->foldingCode(true)
                ->foldedCode(true) // Folded code will fold the code on form load
                ->readOnly(false), // Set to true to make the field read-only
        ]);
}
```

### Infolists

[](#infolists)

```
use CodebarAg\FilamentJsonField\Infolists\Components\JsonEntry;

...

public function infolist(Infolist $infolist): Infolist
{
    return $infolist
        ->schema([
            JsonEntry::make('json')
                ->label('JSON Data')
                ->lineNumbers(true)
                ->lineWrapping(true)
                ->autoCloseBrackets(true)
                ->darkTheme(true)
                ->foldingCode(true)
                ->foldedCode(true), // Folded code will fold the code on form load
        ]);
}
```

### Options

[](#options)

The following options are currently supported:

OptionSupportedDescriptionLine Numbers✅Display line numbers in the editorLine Wrapping✅Enable line wrapping for long linesAuto Close Brackets✅Automatically close brackets and quotesDark Theme✅Enable dark theme stylingFolding Code✅Enable code folding functionalityFolded Code✅Start with code folded (forms only)Read Only✅Make the field read-only (forms only)### Features

[](#features)

- **CodeMirror Integration**: Powered by CodeMirror 5 for excellent JSON editing experience
- **Syntax Highlighting**: Full JSON syntax highlighting with validation
- **Error Handling**: Built-in JSON validation with user-friendly error messages
- **Responsive Design**: Works seamlessly across different screen sizes
- **Customizable**: Extensive configuration options for different use cases
- **Filament 4.0 Ready**: Fully compatible with the latest Filament version

🚧 Testing
---------

[](#-testing)

Copy your own phpunit.xml-file.

```
cp phpunit.xml.dist phpunit.xml
```

Run the tests:

```
./vendor/bin/pest
```

🚧 Building
----------

[](#-building)

```
node bin/build
```

Note: there is no output, but the build will be in the `dist` directory.

📝 Changelog
-----------

[](#-changelog)

Please see [CHANGELOG](CHANGELOG.md) for recent changes.

✏️ Contributing
---------------

[](#️-contributing)

Please see [CONTRIBUTING](.github/CONTRIBUTING.md) for details.

```
composer test
```

### Code Style

[](#code-style)

```
./vendor/bin/pint
```

🧑‍💻 Security Vulnerabilities
----------------------------

[](#‍-security-vulnerabilities)

Please review [our security policy](.github/SECURITY.md) on reporting security vulnerabilities.

🙏 Credits
---------

[](#-credits)

- [Rhys Lees](https://github.com/RhysLees)
- [Sebastian Fix](https://github.com/StanBarrows)
- [All Contributors](../../contributors)
- [Skeleton Repository from Spatie](https://github.com/spatie/package-skeleton-laravel)
- [Laravel Package Training from Spatie](https://spatie.be/videos/laravel-package-training)

🎭 License
---------

[](#-license)

The MIT License (MIT). Please have a look at [License File](LICENSE.md) for more information.

###  Health Score

40

—

FairBetter than 86% of packages

Maintenance90

Actively maintained with recent releases

Popularity2

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 78% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

51d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/25251620?v=4)[EthanLau](/maintainers/EthanLau)[@ethanlau](https://github.com/ethanlau)

---

Top Contributors

[![RhysLees](https://avatars.githubusercontent.com/u/43909932?v=4)](https://github.com/RhysLees "RhysLees (46 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (7 commits)")[![fdw0304](https://avatars.githubusercontent.com/u/18376804?v=4)](https://github.com/fdw0304 "fdw0304 (3 commits)")[![laravel-shift](https://avatars.githubusercontent.com/u/15991828?v=4)](https://github.com/laravel-shift "laravel-shift (2 commits)")[![professor93](https://avatars.githubusercontent.com/u/5443574?v=4)](https://github.com/professor93 "professor93 (1 commits)")

---

Tags

laravelCodebarAglaravel-filament-json-field

###  Code Quality

TestsPest

Static AnalysisPHPStan

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/myhayo-laravel-filament-json-field/health.svg)

```
[![Health](https://phpackages.com/badges/myhayo-laravel-filament-json-field/health.svg)](https://phpackages.com/packages/myhayo-laravel-filament-json-field)
```

###  Alternatives

[codebar-ag/laravel-filament-json-field

A Laravel Filament JSON Field integration with CodeMirror support

1126.6k](/packages/codebar-ag-laravel-filament-json-field)[codewithdennis/filament-select-tree

The multi-level select field enables you to make single selections from a predefined list of options that are organized into multiple levels or depths.

330530.5k30](/packages/codewithdennis-filament-select-tree)[filament/filament

A collection of full-stack components for accelerated Laravel app development.

3929.6M3.9k](/packages/filament-filament)[rawilk/profile-filament-plugin

Profile &amp; MFA starter kit for filament.

3914.8k](/packages/rawilk-profile-filament-plugin)[tomshaw/electricgrid

A feature-rich Livewire package designed for projects that require dynamic, interactive data tables.

119.4k](/packages/tomshaw-electricgrid)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
