basic-example

Super-simple application for chaplin home page.

  • Owner: chaplinjs/basic-example
  • Platform:
  • License::
  • Category::
  • Topic:
  • Like:
    0
      Compare:

Github stars Tracking Chart

Basic example

This is a very minimal HTML5 application built with Brunch builder
that uses Chaplin web framework on top of Backbone MVC library.

Getting started

  • Install Brunch: npm install -g brunch.
  • Install Brunch plugins: npm install
  • Install Bower components: bower install
  • Watch the project with continuous rebuild by
    brunch watch --server. This will also launch HTTP server.
  • Build the minified project with brunch build --optimize.
  • Open the public/ dir to see the result.
  • Write your code in app dir, install dependencies with Bower.

See Chaplin site for docs and more info.

How it works

  1. Route (URL) match.

  2. Controller initialization.

  3. Model and view initialization.

  4. When you navigate to URL in Chaplin application,
    Chaplin.Router instance tries to match URL against
    all routes defined in routes property passed to
    Chaplin.Application (see app/initialize).

  5. If successful, Chaplin.Dispatcher loads corresponding controller.
    If route specifies users#show, it will load controllers/users-controller.

  6. Controller initializes models and views as instance properties.
    Previous controller and its models / views are auto-cleaned-up.

License

The MIT license.

Copyright (c) 2012 Paul Miller (http://paulmillr.com/)

Copyright (c) 2012 Moviepilot GmbH, 9elements GmbH et al.

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

Main metrics

Overview
Name With Ownerchaplinjs/basic-example
Primary LanguageCoffeeScript
Program languageCoffeeScript (Language Count: 1)
Platform
License:
所有者活动
Created At2013-04-13 04:36:33
Pushed At2013-10-07 20:33:31
Last Commit At2013-10-07 22:32:43
Release Count0
用户参与
Stargazers Count13
Watchers Count12
Fork Count9
Commits Count15
Has Issues Enabled
Issues Count1
Issue Open Count0
Pull Requests Count1
Pull Requests Open Count0
Pull Requests Close Count0
项目设置
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private