6. Reusable reusability
2. Handle multiple languages
3. Compile scripts and styles
4. Abstract data by type
The ElseApps Framework stands on the shoulders of giants. Open-source giants. It’s a LAMP stack web application, so obviously it owes a debt to the developers who gave us Linux, the Apache web server, the MySQL database and PHP. But it also relies on the LESS stylesheet language, Twitter’s Bootstrap presentation framework and the Javscript library jQuery. And the list of debts owed doesn’t stop there.
For context sensitive help we elected to use Richard Bondi’s Wiki Web Help, which we’d previously customised for another project to make the pages role-specific.
Knitting all this together is a PHP MVC library called Fat Free Framework or F3, which provides routing, templating, caching, and many of the other goodies that made the creation of the ElseApps Framework possible.
If you read the credits for each of the above open source tools, you’ll find much longer lists of contributors. The strength of open source software is the ability to reuse the building blocks that already exist.
When we were designing the ElseApps Framework we wanted to ensure our own code was also as reusable as possible. Applying this principle led to EAF’s dynamic web forms (see 4. Abstract data by type) and to our generic Knockout-based table class, which is used throughout the web application to present dynamic tabular data that’s paginated and filtered, and automatically stores user settings.
When any setting on a table page is changed, the page automatically counts down the configurable Reload pause interval, while offering a button to pre-empt the delay. When the pause is complete, the user is advised when the data is being reloaded, and when the reload is complete.
All this functionality can be reused anywhere within EAF without coding.
The table class is just one example of the sort of reusability we’ve baked into the ElseApps Framework from the outset. Over time the initial investment in reusability has reaped dividends far in excess of the upfront cost. Most client-requested customisations are easily implemented because we’ve ensured our own code, as well as the underlying open-source building blocks, is easily reused.
Next time? We have configurability in our sights (and in our sites) as we continue our lessons from EAF.