crazy252/typo3_features
Composer 安装命令:
composer require crazy252/typo3_features
包简介
Feature Flags for TYPO3
README 文档
README
Introducing the new open-source package for TYPO3, designed to streamline feature management through the use of feature flags. This package empowers developers and site administrators with a flexible and intuitive backend interface for creating and managing feature flags, enabling granular control over feature deployments. Whether you're rolling out new features incrementally, running A/B tests, or customizing user experiences, our package supports both standard and custom flags, offering a robust solution for feature toggling directly within TYPO3. Unlock seamless feature control and ensure your site's features are deployed smoothly and efficiently.
Features
- Custom Features via TYPO3 Backend
- Validate multiple Features at once
- Make your own feature class
- Fluid ViewHelper
- User and Group check for Features (Frontend & Backend)
- Compatible with TYPO3 7-13
composer require crazy252/typo3_features
Usage
You can use the original features core class from TYPO3. This class is extended by this package with a lot of new features.
use TYPO3\CMS\Core\Configuration\Features; $features = GeneralUtility::makeInstance(Features::class); $isFeatureEnabled = $features->isFeatureEnabled('dummy-feature'); // You can also check multiple features if you want $isFeatureEnabled = $features->isFeatureEnabled('dummy-feature,other-feature');
Own feature class
You can also create your own logic for the feature check by adding the class namespace in the backend feature. After the feature is created in the backend, you can create a feature class with the interface from the package
namespace Vendor\Extension\Features; class DummyFeature implements \Crazy252\Typo3Features\Contracts { public function verdict(): bool { // Custom feature check } }
Feature ViewHelper
This package gives also an viewhelper to check for features in the template. TYPO3 13.1 has an viewhelper for this. Before that, we backport the viewhelper to older versions.
<f:feature name="dummy-feature"> This is being shown if the flag is enabled </f:feature> <f:feature name="dummy-feature,other-feature"> This is being shown if both flags are enabled </f:feature>
Usage (TYPO3 9.0 or below)
You need to use the legecy class for features which can be replaced in higher versions easily with the feature core class.
use Crazy252\Typo3Features\Legacy\Features; $features = GeneralUtility::makeInstance(Features::class); $isFeatureEnabled = $features->isFeatureEnabled('dummy-feature'); $isFeatureEnabled = $features->isFeatureEnabled('dummy-feature,other-feature');
crazy252/typo3_features 适用场景与选型建议
crazy252/typo3_features 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 2 次下载、GitHub Stars 达 0, 最近一次更新时间为 2024 年 07 月 29 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 crazy252/typo3_features 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 crazy252/typo3_features 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 2
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 2
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: GPL-3.0-or-later
- 更新时间: 2024-07-29