Skip to content

Instantly share code, notes, and snippets.

View FranckErnewein's full-sized avatar

Franck Ernewein FranckErnewein

View GitHub Profile
@FranckErnewein
FranckErnewein / Resume.md
Created December 4, 2023 11:05
Resume.md
@FranckErnewein
FranckErnewein / lightstream-liveonly-doc.md
Last active November 13, 2015 17:11
Lighstream liveonly documentation, for highspeed traffic

Lightstream API

Lightstream is a solution which allows you to map any kind of geocalized data in real time. Lightstream API is the backend entry you want to use to push your items, so you can visualize them on the front end. This documentation will help you understand how easy it is to use .

Index

  • Items and types explains why items and types are important in Lightstream
  • API access gives you all information to access the API.
var L = window.L;
var addressPoints = window.addressPoints;
var tiles = L.tileLayer('http://{s}.tile.osm.org/{z}/{x}/{y}.png', {
maxZoom: 18,
attribution: '&copy; <a href="http://osm.org/copyright">OpenStreetMap</a> contributors, Points &copy 2012 LINZ'
}),
latlng = L.latLng(-37.82, 175.24);
var map = L.map('map', {
center: latlng,
@FranckErnewein
FranckErnewein / send.php
Created September 3, 2015 16:54
send data to lightstream API in PHP
<?php
$server = 'test.lightstream.io';
$type = 'ads';
$key = 'b72d053a3722415fab181af70e89a8f2';
$query_string = '?api_key='.$key;
$url = 'http://'.$server.'/api/items/'.$type;
$generated_id = 'test_' . time();

Lightstream API

Lightstream is a solution which allows you to map any kind of geocalized data in real time. Lightstream API is the backend entry you want to use to push your items, so you can visualize them on the front end. This documentation will help you understand how easy it is to use .

Index

  • Items and types explains why items and types are important in Lightstream
  • API access gives you all information to access the API.
var backbone = require('Backbone');
var $ = require('jquery');
// Views Classes
var ListNewsView = require('///');
var NewsView = require('///');
var Home = require('///');
// define router
var MyRouter = Backbone.Router.extend({
var Backbone = require('backbone');
var najax = require('najax');
//set ajax fonction in node
Backbone.ajax = najax;
//create a collection
var Users = Backbone.Collection.extend({
url: 'https://raw.github.com/FranckErnewein/perso/master/www/data/work.json',
});
@FranckErnewein
FranckErnewein / Cube-rotation-with-CSS3.markdown
Created December 4, 2013 09:30
A Pen by Franck Ernewein.
@FranckErnewein
FranckErnewein / Deferred.js
Created November 27, 2013 17:10
jQuery Promise style based on Backbone.Events
define([
'underscore',
'backbone'
], function( _, Backbone ){
function Deferred(){
this.resolved = false;
this.rejected = false;
}