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
| app: | |
| build: . | |
| links: | |
| - db:db | |
| - redis:redis | |
| - memcache:memcache | |
| volumes: | |
| - ./:/app | |
| environment: | |
| PGHOST: db |
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
| import React from 'react'; | |
| let lastScrollY = 0; | |
| let ticking = false; | |
| class App extends React.Component { | |
| componentDidMount() { | |
| window.addEventListener('scroll', this.handleScroll, true); | |
| } |
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
| /** @jsx React.DOM */ | |
| FBLoginMessageComponent = new React.createClass({ | |
| render: function() { | |
| var status = this.props.status; | |
| var message = ''; | |
| if (status === 'logged_in') { | |
| message = 'You\'re already logged in.'; | |
| } else if (status === 'not_logged_in') { | |
| message = 'You\'re not logged in yet.'; |
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
| NSMutableURLRequest *request = [[NSMutableURLRequest alloc] initWithURL:[NSURL URLWithString:@"REST URL PATH"]]; | |
| NSData *imageData = UIImageJPEGRepresentation(image, 1.0); | |
| [request setCachePolicy:NSURLRequestReloadIgnoringLocalCacheData]; | |
| [request setHTTPShouldHandleCookies:NO]; | |
| [request setTimeoutInterval:60]; | |
| [request setHTTPMethod:@"POST"]; | |
| NSString *boundary = @"unique-consistent-string"; |
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
| .ui-datepicker { | |
| background-color: #fff; | |
| border: 1px solid #66AFE9; | |
| border-radius: 4px; | |
| box-shadow: 0 0 8px rgba(102,175,233,.6); | |
| display: none; | |
| margin-top: 4px; | |
| padding: 10px; | |
| width: 240px; | |
| } |
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
| 'use strict'; | |
| /** | |
| * AccountController allows the User to change settings, link with their GitHub accounts, etc | |
| */ | |
| skeletonApp.controller('AccountController', [ | |
| '$scope', '$location', '$rootScope', 'OAuthService', 'ParseService', function($scope, $location, $rootScope, OAuthService, ParseService) { | |
| // redirect to "/login" if user is not logged in |
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
| function toUTF8Array(str) { | |
| var utf8 = []; | |
| for (var i=0; i < str.length; i++) { | |
| var charcode = str.charCodeAt(i); | |
| if (charcode < 0x80) utf8.push(charcode); | |
| else if (charcode < 0x800) { | |
| utf8.push(0xc0 | (charcode >> 6), | |
| 0x80 | (charcode & 0x3f)); | |
| } | |
| else if (charcode < 0xd800 || charcode >= 0xe000) { |
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
| <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
| xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> | |
| <Style | |
| x:Key="ButtonFocusVisual"> | |
| <Setter | |
| Property="Control.Template"> | |
| <Setter.Value> | |
| <ControlTemplate> | |
| <Rectangle Margin="2" SnapsToDevicePixels="true" Stroke="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" StrokeThickness="1" StrokeDashArray="1 2" /> | |
| </ControlTemplate> |
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
| function refreshData() | |
| { | |
| x = 5; // 5 Seconds | |
| // Do your thing here | |
| setTimeout(refreshData, x*1000); | |
| } |
NewerOlder