Skip to content

Instantly share code, notes, and snippets.

@neilff
neilff / angular-http-service
Created December 14, 2013 20:39
angular-http-service
define(
[ 'app', 'services' ],
function ( app, services ) {
return angular.module('drivecam.services').service('RequestService',
['SessionService', '$http', '$resource', '$rootScope', '$cookies',
function(SessionService, $http, $resource, $rootScope, $cookies) {
/**
* @param config {object} - Object which contains all the configuration settings for $http
* @return {object} - $http object which success and error methods
@rickydazla
rickydazla / collections.liquid.html
Created December 17, 2011 05:42 — forked from davecap/collections.liquid.html
"Infinite" (non-auto) scrolling in Shopify collections
{% paginate collection.products by 20 %}
<ul class="collection-matrix">
{% for product in collection.products %}
<li id="product-{{ forloop.index | plus:paginate.current_offset }}">
{% include 'product' with product %}
</li>
{% endfor %}
<li class="top"><a href="#collectionpage">Back to Top</a> &uarr;</li>
{% if paginate.next %}
<li class="more">&darr; <a href="{{ paginate.next.url }}">More</a></li>
@davecap
davecap / collections.liquid.html
Last active March 19, 2024 13:08
"Infinite" scrolling in Shopify collections
{% paginate collection.products by 20 %}
<!-- the top of your collections.liquid -->
<!-- START PRODUCTS -->
{% for product in collection.products %}
<!-- START PRODUCT {{ forloop.index | plus:paginate.current_offset }} -->
<div class="product" id="product-{{ forloop.index | plus:paginate.current_offset }}">
{% include 'product' with product %}
</div>
<!-- END PRODUCT {{ forloop.index | plus:paginate.current_offset }} -->