Photogallery: RequireJS, Marionette.js and Flickr API

javascript, requirejs, marionette, flickr

Another quick example of use RequireJS and Marionette.js together. In this application the user can search public photos on by tags Flickr.

How it works?

This is our basic layout:

Let configure RequireJS, resolve some dependencies and start our application:

Create a Marionette application and put this code:

The SearchView listens the "keyup" event and dispatches the current input value.

The GalleryView is very simple: it has a collection and uses an "ul" as tag:

The GalleryItemView is the childView of GalleryView, it defines a basic template to display the image:

You can download the code from: Gist