This talk will cover different thoughts and experiences that we go through when developing, and try to make us think about our approach and technology choices.
This file contains hidden or 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
original_js = File.binread("app/assets/javascripts/application.js") | |
if original_js.include?("require 'my_engine'") | |
say_status("skipped", "insert into app/assets/javascripts/application.js", :yellow) | |
else | |
insert_into_file "app/assets/javascripts/application.js", :after => %r{//= require ['"]?jquery['"]?} do | |
"\n//= require 'my_engine'\n\n" | |
end | |
end |
This file contains hidden or 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
// dataArray is the nsdictionary/array containing you list of names; we take the 1st letter of each, and compare it with the title of the Index the user "clicked" on | |
// we cycle through all your names until we find a name starting with the letter that he touched in the index. When we found the name, we scroll the table tot that row. | |
- (NSInteger)tableView:(UITableView *)tableView sectionForSectionIndexTitle:(NSString *)title atIndex:(NSInteger)index { | |
for (int i = 0; i< [dataArray count]; i++) { | |
NSString *letterString = [[dataArray objectAtIndex:i] substringToIndex:1]; | |
if ([letterString isEqualToString:title]) { | |
[tableView scrollToRowAtIndexPath:[NSIndexPath indexPathForRow:i inSection:0] atScrollPosition:UITableViewScrollPositionTop animated:YES]; | |
break; | |
} |