ekremogul/tena-editor 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

ekremogul/tena-editor

最新稳定版本:v1.1

Composer 安装命令:

composer require ekremogul/tena-editor

包简介

TenaHaber EditorJS Helper

README 文档

README

It was created by combining editor-js/editorjs-php and alaminfirdows/laravel-editorjs packages.

Special thanks to the developers

Installation

You can install the package via composer:

composer require ekremogul/tena-editor

You can publish the config file with:

php artisan vendor:publish --tag="tena-editor-config"

Optionally, you can publish the views using

php artisan vendor:publish --tag="tena-editor-views"

Usage

use Ekremogul\TenaEditor\TenaEditor;
use App\Models\Post;

$post = Post::find(1);
echo TenaEditor::render($post->body);

// Or use in blade
{!! \Ekremogul\TenaEditor\TenaEditor::render($post->body) !!}

Defining An Accessor

<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Ekremogul\TenaEditor\TenaEditor;

class Post extends Model
{
    public function getBodyAttribute(){
        return TenaEditor::render($this->attributes['body']);
    }
}

// usage
$post = Post::find(1);
echo $post->body;
// or use in blade
{!! $post->body !!}

统计信息

  • 总下载量: 7
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2023-05-12