CODE GENERATION FRAMEWORK FOR FLUTTER

0
528

CHAPTER ONE

INTRODUCTION

1.1 Intrоduсtіоn

Code generation describes the process of automatically producing codes that would otherwise have to be typed manually by hands. This helps to speed up development process. Code generation is possible with a package that has code build. Code build defines the interfaces for creating a builder which is a way of doing codegen that is compatible across build systems (bazel, standalone runner, pub).When a builder is applied to a subset of files in a package, the package can be broken up into multiple targets. Targets are configured in the target section of the build.yaml. The key for each target makes up a name for that target. To get the target, code generator must map intermediate program into a code sequence that can be executed by the target machine.

Developers don’t like writing duplicate or boilerplate code. It could be time consuming and error prone. With code generation a minimum syntax is written and still able to get things done right.

In this research, the focus will be on code generation framework for flutter. Flutter is a mobile user interface framework used in creating native applications for androids and iOS and the Apps created could have access to platform API, digital camera and microphone. The great thing is that you only have to use a single code-base (dart) platform and the Apps would run in different operating systems (e.g iOS and Android). Dart is a programming language that enable you to work with a single code i.e a point where you only have to write your app once for multiple devices.

Other benefits of using flutter to create native apps are only 1 code base, very smooth and quick experience when running apps, good layout methodology borrowed from responsive web, works well with firebase as a backend, great docs and guides on the flutter websites and it uses materials designed out of the box.