Skip to content

Instantly share code, notes, and snippets.

View aaronksaunders's full-sized avatar

Aaron K Saunders aaronksaunders

View GitHub Profile
@aaronksaunders
aaronksaunders / closet.js
Created March 31, 2015 22:49
Set of files for testing the Appcelerator Cloud Services Sync Adapter using Titanium Alloy - https://github.com/aaronksaunders/acs-adapter-starter
//
// Use with - https://github.com/aaronksaunders/acs-adapter-starter
// THIS IS FOR GENERIC OBJECTS NOT DEFINED BY APPCELERATOR
//
// app/models/closet.js
//
exports.definition = {
config : {
"columns" : {},
@aaronksaunders
aaronksaunders / snippet.js
Created March 23, 2015 20:44
longpress click hack until open issue is addressed
function map_longClick(e) {
if(OS_IOS){
var coordinate = convertPixeltoLatLng(e.x, e.y);
}
if(OS_ANDROID){
var coordinate = {latitude: e.latitude, longitude: e.longitude};
}
@aaronksaunders
aaronksaunders / index.js
Created March 17, 2015 13:32
From Simple Appcelerator Titanium Alloy App Videos - https://www.youtube.com/watch?v=Sz_V5HAqroU
//
var peopleService = require('peopleService');
/**
* called when user clicks on table view. The _event will provide
* the index of the item clicked in the table
*
* @param {Object} _event
*/
function clickedOnTableView(_event) {
<html >
<head lang="en">
<meta charset="UTF-8">
<title>Assignment 1</title>
<script src="//cdnjs.cloudflare.com/ajax/libs/angular.js/1.3.13/angular.js"></script>
</head>
<!-- specify the application AND the controller -->
<body ng-app="starter" ng-controller="SimpleController">
<div>
@aaronksaunders
aaronksaunders / Collection-Repeat-w--$http-and-$resource-Factory-Example.markdown
Last active August 29, 2015 14:15
Collection Repeat w/ $http and $resource Factory Example
@aaronksaunders
aaronksaunders / Flickr-Search-Example:-Using-Controller-As-syntax-and-ui-router-resolve.markdown
Last active May 10, 2017 20:04
Flickr Search Example: Using Controller As syntax and ui-router resolve

Flickr Search Example: Using Controller As syntax and ui-router resolve

Demo of loading images using the Flickr API with IonicFramework

showing ui-router functionality of controller as for cleaner looking code.

A Pen by aaron k saunders on CodePen.

License.

@aaronksaunders
aaronksaunders / 0_readme.md
Last active August 29, 2015 14:14
Weird Click Event Inconsistency with 3.5.0GA and Appcelerator NavigationWindow

Weird Click Event Inconsistency with 3.5.0GA and Appcelerator NavigationWindow

when you use this code, sometimes the click event on the button is ignored... nothing shows up in the alert when you click using the latest 3.5.0 SDK on IOS

This seems that it worked fine in 3.4.1

thanks to @skypanther I found that there is a known issue https://jira.appcelerator.org/browse/TIMOB-17367

@aaronksaunders
aaronksaunders / Tabs-with-Sign-In-Using-Authentication-Service.markdown
Created January 31, 2015 18:44
Tabs with Sign-In Using Authentication Service
@aaronksaunders
aaronksaunders / Promise-sample-for-Cross-Platform-mobile-application-class.markdown
Created January 29, 2015 16:15
Promise sample for Cross-Platform mobile application class

To implement API authentication in KeystoneJS, you need the following:

For key based authentication

  • Middleware that validates the key in the request body or a header

For session based authentication

  • An endpoint that handles signin
  • An endpoint that handles signout