how to use nette/forms as its minimal form

Notice: This thread is very old.
Ja
Member | 260
+
0
-

Hi,
I need minimal version of nette/forms and I thought it should be the standalone part which can be used without anything else. As I see in composer, it looks like it is not the whole true.

  1. Do nette/forms need for itself another libs as I see it in composer?
<?php
	"require": {
		"php": ">=5.3.1",
		"nette/component-model": "~2.2",
		"nette/http": "~2.2",
		"nette/utils": "~2.2"
	},
	"require-dev": {
		"nette/tester": "~1.0",
		"latte/latte": "~2.2",
		"tracy/tracy": "~2.2"
	},
?>
  1. How could I use nette/forms without Composer? Should be sufficient to include src/Forms/Form.php?

thanks in advance!

matopeto
Member | 395
+
0
-

i use only:

<?php

{
	"require": {
		"nette/forms": "@beta"
	},
	"minimum-stability": "beta"
}

?>

If in composer are dependencies, nette forms can't do job without them.

And then:

<?php

<?php
require 'vendor/autoload.php';

use Nette\Forms\Form;

$form = new Form;

$form->addText("uri", "Uri")->setRequired()->setAttribute("size", 100);

...

?>

Last edited by matopeto (2014-04-25 18:32)

Ja
Member | 260
+
0
-

Will try, thanks!

Btw, what do these "@beta" (I mean @)

and “minimum-stability”: “beta” mean?

Ja
Member | 260
+
0
-

And finally – I remember there were minified versions of nette, how could be this achieved now when there are 20 separate parts of nette?