ttree/eel-estimatedreadingtime 问题修复 & 功能扩展

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

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

ttree/eel-estimatedreadingtime

Composer 安装命令:

composer require ttree/eel-estimatedreadingtime

包简介

EEL Helper to estimate reading time of a document

README 文档

README

This package calculate a estimated reading time for the given document.

Installation

composer require ttree/eel-estimatedreadingtime

Usage

The package provide a service an EEL Helper and a Fusion prototype.

You can use the EEL Helper, if you have the content string in variable content, like this:

${EstimatedReadingTime.get(content)}

The method get accept an addtionnal parmater, the reading speed, expresed in words per minute. By default this value is 200. You can change the value in your Settings.yaml or in the expression:

${EstimatedReadingTime.get(content, 240)}

The Fusion prototype use the ContentCollection prototype provided by Neos, to render the content at the given path:

prototype(You.Site:ReadingTimeLabel) < prototype(Neos.Fusion:Value)
	readingTime = Ttree.Eel.EstimatedReadingTime:Get {
		nodePath = 'main'
	}
	value = ${'Read the article (' + this.readingTime + ' min.)'}
}

For a correct estimate, the document node must be available in the node context variable.

Acknowledgments

Development sponsored by ttree ltd - neos solution provider.

We try our best to craft this package with a lots of love, we are open to sponsoring, support request, ... just contact us.

License

Licensed under MIT, see LICENSE

统计信息

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

GitHub 信息

  • Stars: 4
  • Watchers: 2
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2018-02-13

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固