v5.0.0
Full diff from previous release 4.1.0...5.0.0
What's new in the major version? 🆕
- [conventions] For rendering partials and layouts is endorsed a new "pure PUG" approach instead of using PHP helper functions such as
render_partial()
. New practices are reflected in the updated documentation @ https://wordless.readthedocs.io/en/5.0.0/_pages/usage/rendering_pug.html - A new PHP helper
render_static()
is provided as a strategy to cache partials or whole templates as static HTML files. Usage and info documented @ https://wordless.readthedocs.io/en/5.0.0/_pages/appendix/render_static.html. This tool works only with PUG files. - A new class
Wordless\Component
is provided as a device to write visual components in PUG with validated parameters using PUG's builtinsmixins
. You can read ratio and usage @ https://wordless.readthedocs.io/en/5.0.0/_pages/usage/filters.html#wordless-pug-configuration - [vendor] Mobile-Detect updated
- [vendor] pug-php updated
- [vendor] Symphony validator added
- [vendor] All javascript dependancies (node modules) updated. A special mention goes to Webpack that receives an update to the recent release 5!
Please be sure to welcome the new "pure PUG" convention, since it will determine a serious performance improvement. Should you have problems refactoring an old theme in order to update it to the new conventions, feel free to open an issue (or ping me in private company chat).
Warning ⚠️
- Default pug compile options were updated. Be sure they still fit your project if you're upgrading: https://wordless.readthedocs.io/en/5.0.0/_pages/usage/filters.html#wordless-pug-configuration
- [conventions] new file naming conventions - as endorsed in the docs - no more relies on underscore-prefixed pug partials. Partials are now called with explicit paths: no underscore magic, no extension omissions.
Fixed 🐛
- Fixed a bug during the the setup preventing the correct creation of the test database
Other changes 📓
- VSCode plugin recommendations added to vanilla theme (fd269cc)
- Documentation was re-ordered trying to make it more focused on important things and more readable
Upgrading from 4.1
Version 5, while introducing a lot of new practices, naming conventions and scaffolding, retains full compatibility with 4.1's themes.
Big ups to @danielegiorgis who put a lot of effort in this major release.