Tale of flux-cli
If you’ve been keeping up with the latest web related technologies, flux architecture shouldn’t be new to you. If you are not familiar with flux, let me give you a brief explanation of what flux is and how it can fix many things which traditional architectural styles cannot accomplish.
Meet flux
Flux is an application architecture for building user interfaces, presented by Facebook. At least that’s the description they give on their website. Primarily flux provides the structure for JavaScript driven web applications. In architectures like MVC, data can flow in different ways. But flux has a different approach when it’s dealing with data. Flux tells you to handle the flow of data in a single direction or in other words one directional data flow. This has several advantages.
- Maintainability
- Scalability
- Performance
Creating a web application with flux could yield these benefits. Even though Facebook provides the architecture, they don’t mention a specific folder structure to start off with flux. But they offer developers with a common way organizing a traditional flux application. Hope you noticed the word traditional, this is because flux has grown over the years and more mature and simplistic libraries are being built on top of the idea behind flux, like redux.

It takes a lot of boilerplate code to deal with traditional or what I like to call it pure flux. When you are creating a large application and working against the deadlines, you need something to speed up your work. That’s why I created flux-cli.
flux-cli to the rescue
flux-cli is based on pure/traditional flux in terms of the folder structure. Like I mentioned working with the huge boilerplate code base can be cumbersome. flux-cli is a command line interface. You can do the basic scaffolding of an application with flux-cli. Options include to start off a fresh project with all the basic and most needed dependencies, generate separate files (actions, components, constants, stores) based on the module that you’re working on.
flux-cli is an open source project and made to solve my problem with the boilerplate code.
Even though flux has evolved over the years with libraries like redux, pure flux can be a better place to start-off, which will eventually lead you to an in-depth understanding about the flux architecture.
Hope you’ll try out flux-cli, share your thoughts and if you have any issues report on github.