Nette Framework 2.1.0 finally released!
Notice: This thread is very old.
- David Grudl
- Nette Core | 8218
After two years of development we are very proud to announce the availability of Nette Framework 2.1.0!
New release has many innovations (see migration guide):
Application & Presenter
- PresenterFactory: configurable mapping Presenter name → Class name
- Route: new pseudo-variables
%basePath%
,%tld%
and%domain%
- Presenter: new method
sendJson()
Caching
- added SQLite storage
(
Nette/Caching/Storages/SQLiteStorage
)
Database (NDB)
- complete refactoring, a ton of bug fixes
- lazy connection
- much better (dibi-like) SQL preprocessor
- Selection, ActiveRow: insert() & update() methods return row instances with refetched data
- Selection: added placeholder support select(), group(), having(), order() methods
- SqlLiteral: added placeholder support
- Selection: added WHERE conditions consider NOT for IN operator
- new driver for Sqlsrv
- Sqlite supports multi-inserts
Debugger
- Bar: you can see bar after redirect
- Dumper: colored and clickable dumps in HTML or terminal
- Debugger: full stack trace on fatal errors (requires Xdebug)
Dependency Injection (DI)
- auto-generated factories and accessors via interface
- adding compiler extensions via config file
- configurable presenters via config file
- annotation @inject
- bullet syntax for anonymous services
Forms
- setOmitted: excludes value from $form->getValues() result
- implemented full validation scopes
- Form::getOwnErrors() returns only errors attached to form
- Radiolist::getLabel(…, $key) returns label for single item
- added ChoiceControl, MultiChoiceControl and CheckboxList
- SelectBox and CheckboxList: allowes to disable single items
- UploadControl allowes multiple files upload
- validators
Form::INTEGER
,NUMERIC
andFLOAT
converts values to integer or float - validator
Form::URL
prependshttp://
to value Form::getHttpData($htmlName)
returns data for single field- supports Twitter Bootstrap 2 & 3 (see examples)
- removed dependency on Environment
- improved toggles
- data-nette-rules attribute is JSON
Latte
- supports
<tag attr=$val>
without quotes - new macro
n:name
for<form> <input> <select> <textarea>
- partially rendered radiolists using
{input name:$key}
and{label name:$key}
- new modifier
|safeurl
which allowes only http(s), ftp and mailto protocols - safeurl is automatically used for
href
,src
,action
andformaction
attributes (can be bypassed by|nosafeurl
modifier) - new modifier
|noescape
which is preferred over exclamation mark {foreach ...|nointerator}
bypasses creating variable$iterator
- new macro
n:ifcontent
{include block}
can be written without hash
Http
- added new SessionPanel
- RequestFactory: new method
setProxy()
Utils
- new utility class
FileSystem
- new utility class
Callback
- Arrays: new method
isList()
- Arrays: method
flatten()
supports key preserving - Strings: new methods
findPrefix()
andnormalizeNewLines()
- Json: supports pretty output
- Validators: new method
isType()
Mailing
- SmtpMailer: persistent connection
Others
- minified version is PHAR file
- ObjectMixin: magic methods setProperty(), getProperty(), isProperty() and addProperty() by @method
- SafeStream: supports
ftruncate
(requires PHP 5.4+)
Nette Framework also comes with updated documentation. How to get started? Try Quick Start tutorial.
- Filip Procházka
- Moderator | 4668
Czech quickstart was updated too. Documentation was updated by @dg (what was missing).
Last edited by Filip Procházka (2014-01-02 11:36)
- David Grudl
- Nette Core | 8218
Quick start is updated and updating of documentation is still in progress.
- Jan Tvrdík
- Nette guru | 2595
Wow, the forms are even better than I thought! Well done =)
Last edited by Jan Tvrdík (2014-01-05 01:05)
- Jan Tvrdík
- Nette guru | 2595
No Ok, it is a hard to spot typo
Last edited by Jan Tvrdík (2014-01-08 12:06)