

List of minimalist frameworks - neiesc
https://github.com/neiesc/ListOfMinimalistFrameworks
A list of minimalist frameworks(simple and lightweight).
======
lkrubner
I know this issue has been brought up many times before, but to some extent
the existence of a framework suggests a lack of composability in the language
being discussed. This gets discussed a lot in the context of Clojure, where
people new to Clojure often ask, "Where are the frameworks?"

The more meta-programming that a language allows, the more its functions will
tend to be composable. The more composable it is, the more its libraries can
be tied together without the need for an over-arching framework. The framework
is there to provide needed cohesion at exactly those points where the language
itself does not provide enough meta reflexion to enable fearless mixing of
libraries that have little knowledge of each other.

There is also the historical trend toward lighter frameworks: Rails was
lighter than Struts, and more recently we've seen a flood of frameworks that
are much lighter than Rails.

The Clojure eco-system has gone furthest down this road. Although at first
there was a feeling that there should be a web framework for Clojure (and
people made wonderful efforts with Noir) eventually the consensus of the
community was that it was sufficient to get by with various libraries, some of
which (Ring) have become standards.

We see this with a lot of new Ruby frameworks as well: composability over
centralized organization. Javascript is going down this road as well.

Languages that offer less in the way of meta-programming (PHP) have been
slower to go down this road.

No matter what language you use, the future direction of the trend seems clear
enough: less frameworks, less centralized effort toward organization, more
emphasis on composability, better ability to mix libraries for maximum effect.

~~~
secoif
A fantastic example of this (in javascript) is trending right now on
hackernews – myth.

[https://news.ycombinator.com/item?id=6923141](https://news.ycombinator.com/item?id=6923141)

Look at this implementation: it's just a composition of a bunch of other
libraries. no logic at all. This is how it should be:
[https://github.com/segmentio/myth/blob/master/index.js#L37-L...](https://github.com/segmentio/myth/blob/master/index.js#L37-L45)

~~~
arianvanp
Wow. that's brilliant. As we would say on tumblr " This is why we can have
nice things".

I'm actually experimenting with `scotty` for haskell now. Though a tad limited
(getting sessions to work is a bit whiney) I had a decently working URL-
shortener up and running in an hour of composing haskell modules and writing a
max of 20 lines of code.

This whole micro-framework thing is getting close to my view of the ideal way
of programming. Use as much reusable components at any time. There is always
someone who did what you were trying and probably already did it better. I
prefer investing time in finding the right micro-frameworks then investing
time to learn to program things in new ways (is this a bad thing?). Anyhow, I
see a lot of classmates implementing their new login systems for their little
websites in pure PHP and i'm just staring at them like 'what the hell'.
Especially in things involving security, composable 'micro-modules' are a
blessing. I just combine a few libraries and whoop I got an https server that
securly talks to a database that securly stores credentials and sessions. I
think it's just beautiful.

Okay of course I do implement things myself. that that is more out of
curiosity. I'm like 'hey how does this security stuff work? how do I break
things?' and I read up about it and prototype a little. but I would _never_
use such code in production just because I know someone already did better.

So yeah. to sum it up. programming microframeworks give us this:

* small, modularized code * where each module on its own is at its best * where the composition of these modules is clear. * and the result is highly maintainable code.

I would even want to take it a step further. Where certain kind of frameworks
stick to the same standard. Think Promises/A+ or WAI. Now at any time in the
future, I can give my whole codebase a speed boost by just changing a single
line. Isn't this great?

~~~
collyw
Not surer I understand the popularity of microframeworks, over fuller
frameworks.

Using a large framework like Django should allow you to use "as much reusable
components" at any time, plus you have the advantage of knowing that they will
play nicely together, and should have some sort of consistency between them.
Yes you get a bigger download, but it will be stored on the server, not
downloaded each time a user clicks a link. Less dependencies, as more is
included out of the box.

~~~
tbatterii
bigger frameworks like django tend to get in your way for anything that the
framework was not intended for. not every web app is a "fetch content from db
and display to users"

try doing something workflow heavy on appengine with datastore. The django orm
wont work for datastore, so what you are left with out of the framework is
regex based routing(ewww) and a bunch of crippled components(meaning depending
on an orm you can't use).

django has it's place dont get me wrong, i would use it to quickly squeeze out
internal db backed apps all day. maybe even use it as a cms. But i'd rather
not do those kinds of projects at all.

~~~
collyw
I believe there is a plugin for working with the App engine. And also Django
is modular enough that you only need to use the parts you require. So again, I
don't see the advantage on messing with micro-frameworks, and cobbling
together multiple libraries, when you have one set of libraries that you know
works nicely together.

~~~
tbatterii
> I believe there is a plugin for working with the App engine.

You believe it, I tried it, and it failed, the non-rel project isn't even
under active development anymore. And if appengine had not introduced cloudsql
as an option, django would be useless on that platform.(IMO)

> And also Django is modular enough that you only need to use the parts you
> require.

As I said before, without the django orm, there's not much useful stuff left
in django that will work without it. There's better request routing options
than regex based IMO. There's better form libs and validation libs. There are
certainly better performing template engines, what is left of django that's a
better choice over something else?

------
RyanZAG
What is Log4J doing there? It's an incredibly complex framework for doing
something incredibly simple - logging. It's the exact opposite of a minimalist
framework.

~~~
jeltz
Yeah, I still wonder if it is a joke inclusion or not. Log4j is probably
larger than all other frameworks on that page, and it just handles logging.

------
AndyKelley
Isn't "minimalist framework" a contradiction? It seems like if you were going
for minimalism you would not use a framework.

~~~
rmrfrmrf
I agree. Having just finished a project with Flask, I ended up using no less
than 8 million dependencies that I'd never heard of. "BYO everything"
frameworks would be more appropriate, but even then, Flask brings with it an
entire basement of sub-frameworks that I would argue make it so that you might
as well just use a full-fledged framework like Django.

~~~
mercurial
That's how it works with micro-frameworks, you pay for what you use. Now, it's
not necessarily a problem, last time I checked, there was a decent list of
functional Flask components. What do you feel is the advantage of having a
huge 'contrib' folder, as long as the extensions are maintained? Because the
advantage of _not_ having an ORM bundled per default, and easily switching
something like the templating language are pretty clear to me.

~~~
jsmeaton
I have a django project that swapped out the django templates for mako. Mako
templates are awesome to use. The problem is it becomes extremely difficult to
use packages that have bundled templates of their own. I would think it'd be
the same with flask, no?

Making assumptions about the available ORM and templating package allows 3rd
party modules to do more of the work for you.

~~~
collyw
I have been tempted to switch the Django ORM for SQL alchemy, but I would
loose the Django Amdin interface.

~~~
jsmeaton
..and every 3rd party module that contains their own models, which would be a
very large number.

If you want to use SQL Alchemy, you're better off using a different framework.
I'm currently trying to decide if this is the angle I should follow for my
next project, which requires fairly sophisticated SQL (comparable to the
django ORM anyway).

------
secoif
@neiesc please make this a wiki instead of a readme. Edit wiki much more
conducive to contribution than fork + PR + wait + hope

~~~
josegonzalez
You can edit a markdown page direct from github.

~~~
cmelbye
That's the "Fork" step he mentioned. The "Edit" button on GitHub automatically
forks the project and dumps you into the Markdown editor. The rest of the
steps are still required to get changes merged into a file.

------
manuelflara
Unsurprisingly (I think only a few dozen people know about it), the PHP
framework I use isn't there: [http://sifo.me](http://sifo.me) It's a framework
created by a friend of mine and it's used in quite a few actual businesses
(including my own). I can't say I've looked around much in the PHP framework
landscape in the last few years, so can't compare, but I'm really happy with
it. Simple, flexible and powerful.

~~~
rmrfrmrf
First sentence on the homepage: "Sifo is a well-proben [sic] open source
framework for PHP professionals."

~~~
manuelflara
Will pass it along, thanks. Neither of us are native English speakers.

------
ErikAugust
For PHP - Silex is really awesome.

You get the minimal app controller/router similar to Express. And you can pick
and choose Symfony2 (and other) components to add. It makes putting together
an API for your front-end a snap.

For those interested in this approach, I've put together a boilerplate called
PHANG that combines Silex and AngularJS:
[https://github.com/ErikAugust/phang](https://github.com/ErikAugust/phang)

------
CmonDev
[http://programmingisterrible.com/post/65781074112/devils-
dic...](http://programmingisterrible.com/post/65781074112/devils-dictionary-
of-programming)

"lightweight — I don’t understand the use-cases the alternatives solve."

"minimal — You’re going to have to write more code than I did to make it
useful."

"simple — It solves my use case."

------
stickhandle
Spark ([http://www.sparkjava.com/](http://www.sparkjava.com/)) is the _java_
sinatra

~~~
kitd
See also Google SiteBricks
[http://sitebricks.org/#home](http://sitebricks.org/#home)

------
_neil
I hadn't heard of Cuba before. Grape[1] would also be worth listing in the
Ruby section. It's an actively maintained microframework for REST APIs.

[1] [https://github.com/intridea/grape](https://github.com/intridea/grape)

~~~
xs_kid
Found this nice Sinatra micro-clone thanks to the page:

[https://github.com/guilleiguaran/nancy](https://github.com/guilleiguaran/nancy)

~~~
tiedemann
There's also the Nancy lightweight web framework for .NET
[https://github.com/NancyFx/Nancy](https://github.com/NancyFx/Nancy)
[http://nancyfx.org/](http://nancyfx.org/)

------
karolisd
[https://github.com/aemkei/fishbone.js/](https://github.com/aemkei/fishbone.js/)
\- A super lightweight (½kb) JavaScript library with automatic method
chaining, automatic context binding, event support and simple inheritance.
c-{{{-<

------
monksy
It appears that the focus of this was web frameworks.. but I think that Java
microframeworks should be added here. I created a pull request for that.

~~~
ds_
I have to agree with RyanZAG, log4j seems a strange inclusion in this list.

------
_ak
Shameless plug: [https://github.com/akrennmair/metoo-
pm](https://github.com/akrennmair/metoo-pm)

------
dep_b
I really liked Slim. It just wasn't convoluted or giving an improvised feel
like Laravel or WordPress and many other PHP frameworks.

~~~
girvo
I use Slim, Idiorm, and PHPUnit to build all my projects :)

------
mimog
This list is a lot more extensive for javascript:
[http://microjs.com/#](http://microjs.com/#)

------
owenversteeg
Ooh yay! My CSS framework Min is the smallest of them all!

[http://minfwk.com](http://minfwk.com)

------
euphemize
Missing quite a lot of PHP ones. For instance, tinyMVC is great if you want to
learn how MVC works with PHP.

~~~
girvo
Hah, I wrote an ActiveRecord plugin or TinyMVC back in the day. Should be in
the forums still. Nostalgia!

------
aheilbut
CherryPy doesn't get enough love.

------
stephanos2k
Why is no framework for Go in the list? Oh, that's right: They are all
minimalistic ;)

------
jamesbritt
Quite sparse for Ruby. I'm surprised Innate and Ramaze are not listed, for
example.

------
sunny1304
i dont think you can call Pardino a minimalist framework.

~~~
xs_kid
agree padrino is pretty near to Rails, what's the criteria used to determine
if a framework is minimalist or not?

~~~
al2o3cr
From what I can tell, "minimal" == "makes code hipsters' pants tight". YMMV.

------
granttimmerman
Number of minimalist frameworks for Java: 1

~~~
bodiam
Thats because at least Vert.x, Ratpack and Spark are missing.

