A quick cheatsheet of useful snippet for Flutter
A widget is the basic type of controller in Flutter Material.
There are two type of basic Widget we can extend our classes: StatefulWidget
or StatelessWidget
.
StatefulWidget are all the widget that interally have a dynamic value that can change during usage. It can receive an input value in the constructor or reference to functions. You need to create two classes like:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import upload from "../lib/upload"; | |
// const UPLOADS_DIR = "./public"; | |
// const indexUser = async (c) => { | |
// return c.json({ message: "User Index" }); | |
// }; | |
const storeUser = async (c) => { | |
const body = await c.req.parseBody(); |