-
Notifications
You must be signed in to change notification settings - Fork 120
examples
No examples yet really. Coming soon.
tower new todo --single-page
tower page todo
doctype 5
html ->
head ->
stylus """
html, body
margin: 0
#todos
"""
# http://addyosmani.github.com/todomvc
script src: "https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"
script src: "http://towerjs.org/javascripts/underscore.js"
script src: "http://towerjs.org/javascripts/coffeekup.js"
script src: "http://towerjs.org/javascripts/tower.js"
body ->
coffeescript ->
class window.App extends Tower.Application
class App.Todo extends Tower.Model
@field "id", type: "Id"
@field "name"
@field "done", type: "Boolean"
@scope "active", @where(done: false)
@scope "done", @where(done: true)
class App.TodosController extends Tower.Controller
@on "submit form", "create"
@on "change", "toggle"
@on "click .destroy", "destroy"
index: ->
App.Todo.where(@criteria()).all (error, todos) =>
@render "index"
toggle: ->
@todo.set "done", !@todo.get("done")
@todo.save()
App.views
"todos/_form": ->
"todos/_item": ->
li class: "todo", ->
input type: "checkbox"
span todo.get("name")
a class: "destroy"
"todos/index": ->
"todos/new": ->
"todos/edit": ->
App.routes ->
@resources "todos", pathName: ""
App.run()
You can chat with other node.js hackers too, and send code samples back and forth
tower new node-hacker
cd node-hacker
npm install
tower generate scaffold user firstName lastName email website twitter github
tower generate scaffold company website twitter email description:text founded:date
node server
tower new cached-commons --namespace CC
- site where you can submit awesome sites
- background processing
- site like eventbrite
- geo location
- maps
- subscription billing
- mongodb (should be able to swap out with couchdb)
- passport
- geo location
- subscription billing
- mongodb
- phonegap
- passport
Simple node-relationship interface with 3 inputs at the bottom and a d3.js graph at the top:
[subject]-[action]-[object] Newton mastered physics
Or maybe just try to tell a story:
John meets Stacy Stacy spills water
Or maybe you login to github and it shows your commits and forks to other projects
-
find all projects with > 500 watchers
-
find all people contributing to those projects
-
find all locations of the people
-
the people that commit to one repo who commit to another, there is a link between two repos
-
http://www.kellyrob99.com/blog/2012/05/27/github-social-graphs-with-groovy-and-graphviz/
Or maybe like mrdoob's visualization of commits over time to specific files in threejs
- http://www.youtube.com/watch?v=iJEPadhcOsc
- each file is a node
- each directory is a relationship
- each user has a relationship to a file
- the relatioship has additions/deletions count and a date
- https://api.github.com/repos/viatropos/tower/commits
Find all repos where a user follows a user who forked another repo, that might be a better example. Start with GitHub users with over 1000 followers or 100 repos, then add people as they come. Then grab all the users repos, contributions, forks, and follows
Find commits made by user who made more than 2 commits
nevermind... http://code.google.com/p/gource/
Or, enter in relationship taxonomy (building an ontology of relationships)