This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SampleWindow = require './window' | |
person = new Backbone.Model | |
name: 'John Doe' | |
sampleWindow = new SampleWindow | |
model: person | |
sampleWindow.render().open() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Label= title | |
View(layout='horizontal', top=11) | |
Button.clickable I work! | |
Button.notclickable I don't! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
template = require './template' | |
module.exports = class Window extends Backbone.View | |
viewName: 'Window' | |
attributes: | |
backgroundColor: '#eee' | |
layout: 'vertical' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sublime, sublime_plugin | |
import os, time | |
class RestartPassengerCommand(sublime_plugin.TextCommand): | |
"""Touch tmp/restart.txt file in the rails project to restart pasenger""" | |
def run(self, edit): | |
for folder in self.view.window().folders(): | |
fname = os.path.join(str(folder), 'tmp', 'restart.txt') | |
if os.path.exists(os.path.dirname(fname)): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Default Titanium API | |
button = Ti.UI.createButton | |
title: 'Testing' | |
button.addEventListener 'click', -> | |
alert 'Click!' | |
return | |
@view.add button |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ExtendedView extends View | |
clicked: false | |
events: | |
'click #someChild': 'clickMethod' | |
render: => | |
Backbone.$('<View>') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* Case Conversion | |
* Backbone - Trabian (custom plugin) | |
* ChangeQuotes | |
* CoffeeScript | |
* CTags (with coffeescript ctags) | |
* Git | |
* GitHubinator | |
* Guard (prevents need to keep a separate terminal open for running guard) | |
* Jade | |
* Origami |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
styles = require('styles').ui | |
{ Button, ContentBlock, Window } = require 'views/ui' | |
module.exports = class IntroView extends Window | |
render: => | |
@layout (view) => |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
styles = require('styles').ui | |
{ Button, Window } = require 'views/ui' | |
module.exports = class IntroView extends Window | |
render: => | |
@layout (view) => |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
styles = require('styles').ui | |
KitchenSink = require './main' | |
{ Button, Window } = require 'views/ui' | |
module.exports = class IntroView extends Window | |
render: => |