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
[[[self.propertyA sendSomeInterestingMessage] | |
flattenMap:^RACStream *(SomeOtherObject *param1) { | |
return [self.someProperty someMessage:param1.property]; | |
}] | |
subscribeError:^(NSError *error) { | |
[self.someRacSubject sendNext:nil]; | |
}]; |
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 LoginViewController < UIViewController | |
include Objection::Compose | |
#motion-objection for dependency injection! | |
compose_with :login_table_view_model | |
def viewDidLoad | |
super | |
# Create our table view controller and set various properties | |
@table_view_controller = UITableViewController.alloc.initWithStyle UITableViewStyleGrouped |
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 LoginViewController < UIViewController | |
include Objection::Compose | |
compose_with :login_table_view_model | |
#A stylesheet for all the styles in this controller | |
stylesheet :login_screen | |
def viewDidLoad | |
super |
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
Teacup::Stylesheet.new :login_screen do | |
style :scroll_view, | |
width: '100%', | |
height: '100%', | |
autoresizingMask: UIAutoResizingFlexibleWidth | UIAutoResizingFlexibleHeight | |
style :table_view, extends: :flexible_margins | |
scrollEnabled: false, | |
separatorStyle: UITableViewSeparatorStyleSingleLine, | |
center_x: '50%', |
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
ApplicationAdpater = DS.ActiveModelAdapter.extend | |
synchronizer: Em.inject.service() | |
ajax: (url, type, options) -> | |
hash = @ajaxOptions(url, type, options) | |
# set up hash.success & hash.error callbacks normally | |
@get('synchronizer').handleRequest(hash) |
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 Ember from 'ember'; | |
export default Ember.Component.extend({ | |
}); |
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 Ember from 'ember'; | |
export default Ember.Component.extend({ | |
actions: { | |
selectSuperhero(pub, hero) { | |
this.attrs.selectSuperhero(hero, pub); | |
} | |
} | |
}); |