Several c-lick language editor extensions for laravel-admin based on code-mirror
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src
.gitignore
LICENSE
README.md
composer.json

README.md

Several c-lick language editor extensions for laravel-admin based on code-mirror

DEMO (Login using admin/admin)

Installation

composer require laravel-admin-ext/clike-editor

php artisan vendor:publish --tag=laravel-admin-code-mirror

配置

config/admin.php文件的extensions,加上属于这个扩展的一些配置


    'extensions' => [

        'clike-editor' => [
        
            // 如果要关掉这个扩展,设置为false
            'enable' => true,
            
            // 编辑器的配置
            'config' => [
                
            ]
        ]
    ]

更多配置可以到CodeMirror文档找到

使用

在form表单中使用它:

$form->clang('code');

$form->cpp('code');

$form->csharp('code');

$form->java('code');

$form->objectivec('code');

$form->scala('code');

$form->kotlin('code');

$form->ceylon('code');

设置高度

$form->clang('code')->height(500);

支持

如果觉得这个项目帮你节约了时间,不妨支持一下;)

-1

License

Licensed under The MIT License (MIT).