cocur / slugify

Converts a string to a slug. Includes integrations for Symfony, Silex, Laravel, Zend Framework 2, Twig, Nette and Latte.
MIT License
2.89k stars 252 forks source link

Drop Twig 1 support #238

Closed FabienPapet closed 4 years ago

FabienPapet commented 4 years ago

@florianeckerstorfer I'm not happy with that solution but I think it's the best way to have all twig versions working with any version of slugify.

This code works on twig 3. I didn't wrote any test, I don't know how to test it.

florianeckerstorfer commented 4 years ago

Should we just drop support for Twig 2?

FabienPapet commented 4 years ago

The real problem is twig 1 here I think. If I remember correctly , twig 2 is supporting old and new namespaces. We can make a version that supports only twig ~2.0|~3.0

What do you think ?

florianeckerstorfer commented 4 years ago

@FabienPapet From my perspective this would be totally fine. Once we have Twig 3 support in, I would release a new major version. People who need support for old frameworks would need to use an old version of the library

florianeckerstorfer commented 4 years ago

Thanks for the PR, can you resolve the conflict, then I merge it and release a new version over the weekend