Skip to content
This repository was archived by the owner on Oct 28, 2023. It is now read-only.

lecuivre-alban/easy_forms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

[WIP]

easy_forms

Create forms with less code.

It's simple and fast.

With this package you can create forms without having to manage controllers or variables for your fields (A stateful widget is no longer needed). This package aslo provide some usefull common validators for your fields.

Example

Login form

@override
Widget build(BuildContext context) => EasyForm(
    runSpacing: 8,
    spacing: 8,
    children: [
        EasyTextField(
            hintText: 'Email',
        ),
        EasyTextField(
            hintText: 'Password',
        ),
        EasyFormButton(
            child: Text('Validate'),
            onPressed: (formData){
                final email = formData[0];
                final password = formData[1];
                // query server / send event to a bloc
            }
        ),
    ]
);

Register form

@override
Widget build(BuildContext context) => EasyForm(
    runSpacing: 8,
    spacing: 8,
    children: []
);

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages