定制 tiny-pixel/acorn-block-templates 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

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

tiny-pixel/acorn-block-templates

最新稳定版本:1.1.0

Composer 安装命令:

composer require tiny-pixel/acorn-block-templates

包简介

Block templates for Sage 10

README 文档

README

Easily override block markup with Blade templates in Sage 10.

Requirements

Installation

Install via Composer:

$ composer require tiny-pixel/acorn-block-templates

Usage

Create a blocks directory in resources/views. Templates should be named after the block they target and should be placed within a directory with a name matching the block's namespace.

Example

├── blocks
    └── core
        ├── gallery.blade.php     # core/gallery
        ├── image.blade.php       # core/image
        └── paragraph.blade.php   # core/paragraph

The template is passed two variables: $attr and $content.

  • $attr is an array of the block's attributes.
  • $content is a string of the block's output.

In this way you can override the template for any block, regardless of if it is registered by core or a plugin. You can use Composers, extends, or any other feature afforded to you by Sage, Illuminate or other packages.

Contributing

Contributing, whether it be through PRs, reporting an issue, or suggesting an idea is encouraged and appreciated.

All contributors absolutely must strictly adhere to our Code of Conduct.

License

This project is provided under the MIT License.

统计信息

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

GitHub 信息

  • Stars: 19
  • Watchers: 4
  • Forks: 4
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-02-08