2.0.0 - Beta 1
Pre-releaseThis is the first beta version of the long awaited Version 2 of Timber. We consider this beta feature-complete. We will concentrate on fixing bugs to be able to soon release a first release candidate.
You can try it out by following the Installation Guide. When installing Timber through Composer, you need to quire the 2.0.0-beta.1
version:
composer require timber/timber:2.0.0-beta.1
There are quite a few breaking changes in Version 2 of Timber. Refer to the Upgrade Guide for more information.
The overall goals of Timber 2.0 include:
- Making Timber more consistent.
- Making Timber easier to handle and extend.
- Refactoring how Timber Core works under the hood to improve compatibility with WordPress Core and be ready for future challenges.
- Making Timber more compatible with other plugins.
High-level changes include:
- Timber will only work as a Composer package.
- A newer, streamlined API for accessing Posts, Terms, Users, Comments and Menus.
- Class Maps for a more loosely coupled way to extend Timber with your own Post, Term, User, Menu, MenuItem, and Comment objects.
- No more direct instantiation of the classes mentioned above. Use Class Maps instead.
- New PostCollectionInterface for a unified way to deal with various lists of posts.
- An upgraded Context.
- A big update for how fetching meta values works.
- An updated WP-CLI integration.
- Better options to control and extend Twig.
- Better integration with the WordPress Date and Time functionality.
We’re happy if you want to test out the first Timber beta. In case you find errors, please open an issue (and label with 2.x
and bug
) or create a discussion in case you have questions.
We want to thank so so so many people for being a part of Timber and helping us achieve this milestone. We're so proud of the work and the evolution to a stable and widely-used part of so many developer's tools.
If you've been using the alpha versions, here's what's changed in this version of 1.0.0-beta.1
:
What's Changed
- Add a .git-blame-ignore-revs file by @gchtr in #2606
- 2.x Add missing query() method to
Timber\PostQuery
by @gchtr in #2613 - 2.x Reintroduce Timber’s WP-CLI integration by @gchtr in #2611
- 2.x Remove unused WPML integration class by @gchtr in #2616
- 2.x Remove
Attachment::$caption
property in favor ofAttachment::caption()
method by @gchtr in #2612 - Make snippets CS compliant by @nlemoine in #2620
- 2.x update tests fix indentation by @nlemoine in #2622
- 2.x Fix tests in #2614 by @gchtr in #2621
- Use
yoast/wp-test-utils
by @nlemoine in #2614 - 2.x Document the
timber/menuitem/classmap
filter by @gchtr in #2618 - 2.x Add wp_object() method and $wp_object property for Core objects by @gchtr in #2615
- 2.x Update Upgrade Guide by @gchtr in #2617
- 2x Update CONTRIBUTING.md by @gchtr in #2619
Full Changelog: 2.0.0-alpha.5...2.0.0-beta.1