What is a plugin?
Many programming frameworks and software tools have the concept of plugins. They may go by another name, such as third-party libraries, extensions, or add-ons, but they are effectively the same thing – a self-contained, modular code deliverable that can be "plugged in" to your existing app code to provide extra functionality.
Within this chapter, you will see references to the term packages, a chunk of Dart code, and assets. A plugin is a special type of package that makes functionality available to your app and this is what we are looking at in this chapter.
There are many benefits as well as drawbacks to the plugin approach. So let's take a look and understand why Flutter would choose to use plugins within the framework and then we will move on to the drawbacks.
Benefits
As you would expect, Flutter uses plugins because they bring many benefits. This is especially true of code reuse; creating a great Flutter app would be much harder...