A quick rant.
- PouchDB is slow, because it doesn't use bare-metal IndexedDB
OK, first off I want to point out the CanIUse table for IndexedDB. Go ahead, look at it. I'll wait.
var app = angular.module('app', ['firebase']); | |
app.controller('ctrl', function($scope, $pageArray) { | |
$scope.pageItems = $pageArray(ref, 'number'); | |
}); | |
app.factory('$pageArray', function($firebaseArray) { | |
return function(ref, field) { | |
// create a Paginate reference | |
var pageRef = new Firebase.util.Paginate(ref, field, {maxCacheSize: 250}); |
A quick rant.
OK, first off I want to point out the CanIUse table for IndexedDB. Go ahead, look at it. I'll wait.
;
(function() {
'use strict';
# Build arguments for the gn build | |
# You can set these with `gn args out/Default` | |
# ( and they're stored in src/out/Default/args.gn ) | |
# See "gn args out/Default --list" for available build arguments | |
# component build, because people love it | |
is_component_build = true | |
# release build, because its faster | |
is_debug = true |
Due to the high usage of this guide and the lack of comfort in Gist's commenting area, I decided to make a blog post out of this which you can find here:
http://blog.frd.mn/install-os-x-10-10-yosemite-in-virtualbox/
/* Converts an object into a key/value par with an optional prefix. Used for converting objects to a query string */ | |
var qs = function(obj, prefix){ | |
var str = []; | |
for (var p in obj) { | |
var k = prefix ? prefix + "[" + p + "]" : p, | |
v = obj[p]; | |
str.push(angular.isObject(v) ? qs(v, k) : (k) + "=" + encodeURIComponent(v)); | |
} | |
return str.join("&"); | |
} |
Taken from mathiasbynens/dotfiles. Save time and pain from customising your clean-installed Mac, install web development tools and native applications. It's straight-forward and simple, here's how you run it:
Download osx.sh
and tools.sh
to your desktop, open osx.sh
on your favorite text editor and change these lines:
# Set computer name (as done via System Preferences → Sharing)
sudo scutil --set ComputerName "benjaminbasa"
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>Angular JS</title> | |
</head> | |
<body ng-app="jsbin"> | |
<div ng-controller="DemoCtrl as demo"> | |
<h1>Hello {{demo.name}}</h1> | |
</div> |
/** | |
* Возвращает по дате номер TD в таблице | |
* Использование: | |
* var td = table.find('td').eq(getCellByDate(date)) | |
*/ | |
function getCellByDate(date) { | |
var date1 = new Date(date.getFullYear(), date.getMonth(), 1); | |
return getDay(date1) + date.getDate() - 1; | |
} |
I was chasing down another issue (slow "Save As") and thought these two issues may have been related (with QuickLook being the common broken link). Unfortunately, my "Save As" dialog is still miserably slow on the initial load; but IconServicesAgent hasn't gone above 30MB and he rarely makes an appearance in the Console!
Some of these steps may not be necessary, but here are all of the steps I took that inadverdently put IconServicesAgent back in its place. Note: all commands are a single-line, if they appear to be multiple that's just the forum formatting.
Check for any QuickLooks related .plist files. In a terminal: mdfind com.apple.quicklook. -name .plist
I only had files at the system level (specifically within /System/Library/LaunchAgents/). If you have others, modify the directions below to take that into account (re-introducing plist files from the system level back up to the user).
Make some temporary directories to store these plist files, just in case: mkdir ~/tmp-quicklook