PHPackages                             bitandblack/hyphenizer-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. bitandblack/hyphenizer-bundle

ActiveSymfony-bundle[Utility &amp; Helpers](/categories/utility)

bitandblack/hyphenizer-bundle
=============================

Perfect hyphenation for your Website. This library integrates the Hyphenizer into your Symfony project.

0.0.0(3mo ago)158↓87.3%MITPHPPHP &gt;=8.2

Since Apr 1Pushed 3mo agoCompare

[ Source](https://github.com/BitAndBlack/hyphenizer-bundle)[ Packagist](https://packagist.org/packages/bitandblack/hyphenizer-bundle)[ Docs](https://www.hyphenizer.com)[ Fund](https://www.buymeacoffee.com/tobiaskoengeter)[ RSS](/packages/bitandblack-hyphenizer-bundle/feed)WikiDiscussions main Synced 4w ago

READMEChangelogDependencies (11)Versions (2)Used By (0)

[![PHP from Packagist](https://camo.githubusercontent.com/f9fd57dc5e1553efd26350d0fa58f10e8fa327681630b6aa61bb6eafd5be01f8/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f626974616e64626c61636b2f68797068656e697a65722d62756e646c65)](http://www.php.net)[![Latest Stable Version](https://camo.githubusercontent.com/b3c0ef2193154e5fd84c4efdb1ed7cad9e50f1adc043199ea6c12744fdad0cf1/68747470733a2f2f706f7365722e707567782e6f72672f626974616e64626c61636b2f68797068656e697a65722d62756e646c652f762f737461626c65)](https://packagist.org/packages/bitandblack/hyphenizer-bundle)[![Total Downloads](https://camo.githubusercontent.com/4da35928c4a48a4abe833e8b66a508268aeb3621857d7d5e0de430c33d227513/68747470733a2f2f706f7365722e707567782e6f72672f626974616e64626c61636b2f68797068656e697a65722d62756e646c652f646f776e6c6f616473)](https://packagist.org/packages/bitandblack/hyphenizer-bundle)[![License](https://camo.githubusercontent.com/4294a4a8d6844beee0ee6a7399d0da1c2b94322ad186566a8f757fe8dc3fcd48/68747470733a2f2f706f7365722e707567782e6f72672f626974616e64626c61636b2f68797068656e697a65722d62756e646c652f6c6963656e7365)](https://packagist.org/packages/bitandblack/hyphenizer-bundle)

 [ ![Bit&Black Logo](https://camo.githubusercontent.com/6cd6b1b85b6247964059c5d9420aae54482ebf17afbaf5f08127bc49de5916f4/68747470733a2f2f7777772e626974616e64626c61636b2e636f6d2f6275696c642f696d616765732f426974416e64426c61636b2d4c6f676f2d46756c6c2e706e67) ](https://www.bitandblack.com)

Bit&amp;Black Hyphenizer Bundle
===============================

[](#bitblack-hyphenizer-bundle)

Perfect hyphenation for your Website. This library integrates the [Hyphenizer](https://www.hyphenizer.com) into your [Symfony](https://symfony.com) project.

If you don't run your website with Symfony, you can integrate the [Hyphenizer SDK for PHP](https://packagist.org/packages/bitandblack/hyphenizer-sdk-php) by your own.

**Please note:** The Hyphenizer API requires you to have a valid API token.

Installation
------------

[](#installation)

This library is made for the use with [Composer](https://packagist.org/packages/bitandblack/hyphenizer-bundle). Add it to your project by running `$ composer require bitandblack/hyphenizer-bundle`.

Usage
-----

[](#usage)

### Basic setup and usage of the Bit&amp;Black Hyphenizer Bundle

[](#basic-setup-and-usage-of-the-bitblack-hyphenizer-bundle)

The **Bit&amp;Black Hyphenizer** bundle offers a smooth way to extract and hyphenate long words automatically. It implements the [Hyphenizer SDK for PHP](https://packagist.org/packages/bitandblack/hyphenizer-sdk-php) and allows to update the extracted words.

To use this library in your project, wrap your texts with the [`AutoHyphenation`](./src/AutoHyphenation.php) class. This will add soft hyphens to all words, that are long enough to be hyphenated:

```
