Skip to content

Introduction

FLEX is a platform and ecosystem of starter kits, packages, and tools that help you build modern, scalable and customizable eCommerce storefronts. FLEX provides an opinionated approach and starting point for creating your own commerce mobile and web apps, and allows you to focus on writing clean, productive code for an amazing user experience.

After years of experience building enterprise eCommerce apps, we have formed an opinion on the standard packages, best practices and architecture that allow you to build and deploy amazing, large-scale mobile apps. We created FLEX with the goal of providing a platform that accelerates development, eases maintenance, and gets you live in production!

To use the FLEX CLI, you need to install it globally as an npm package. This allows you to run the flexcli command from anywhere on your system.

Install the CLI globally using npm:

Terminal window
npm install -g flex_cli

After installation, you can verify it by running:

Terminal window
flexcli --version

This should print the installed version of the FLEX CLI.

Before creating your first FLEX app, make sure you have Dart and Flutter installed on your machine.

If you don’t have Dart and Flutter installed, you can follow this guide.

After you have installed Dart, Flutter and the FLEX CLI, you’re ready to create a new FLEX app. The FLEX CLI will prompt you to select your preferred starter kit:

Terminal window
flexcli new example_app

Once the app has been created, you can navigate into your new project directory:

Terminal window
cd example_app

This repository contains the FLEX CLI, a command-line tool designed to streamline the creation and management of Flutter apps using Starter Kits and modular features.

  • Starter Kits: When you run flexcli new, the CLI scaffolds a new Flutter app based on your selected starter kit. Starter kits provide a pre-configured project structure, recommended dependencies, and initial code to help you get started quickly.
  • Features: The CLI supports adding modular features to your app using the flexcli add command. Features are reusable components (such as authentication, onboarding, etc.) that follow best practices and integrate seamlessly into your project.

To add a new feature to your FLEX app, use the following command:

Terminal window
flexcli add feature <feature-name>

Replace <feature-name> with the name of the feature you want to add (for example, auth or profile). The CLI will generate the necessary files and update your project automatically.

Terminal window
flexcli add feature onboarding

This will create a new feature module in your app, including the required Dart files, widgets, and state management (using Cubit if specified).

  • flexcli new <app-name>: Create a new Flutter app from a Starter Kit.
  • flexcli add feature <feature-name>: Add a new modular feature to your app.
  • Explore the generated code and project structure.
  • Add more features as needed using the CLI.
  • Start building your Flutter app!