How to Create Module Package
Create Module Template
After entering
june create
After entering "3" to select the module template
Please choose a module name. The name should be in a format suitable for uploading to pub dev (lowercase and underscores)
Understand About Module System
If you add //@add at the end of libraries in the dependency and devDependency sections of pubspec, those libraries will be installed together when applying this module to the project.
Under lib/util, you can only add files and such to folders that have the module name. If you remove the # at the very beginning inside the add.june file in this folder, all files in the folder will be duplicated when the module is installed.
For assets, you can only place files in pre-prepared folders. If you remove the # at the very beginning inside the add.june file in this folder, all files in the folder will be duplicated when the module is installed.
You can also add code blocks directly to pubspec.yaml. They can be added in the following form:
If there are overlapping files between modules, the build itself will not proceed. Please be careful to ensure that files do not overlap with those of other modules when creating a module.
Dedeply Module
After uploading the module to GitHub,
After registering it in the
repository:
section of pubspec,In the
description:
, you also provide detailed information about the module.In the README.md, you also write the description of the module under "description here".
In the README.md, write how to use it under "Usage here". If not applicable, please delete the #Usage section.
Please register on pub dev by entering the following command.
Please register the module created according to this guide. \
\
Last updated