Fetching contributors…
Cannot retrieve contributors at this time
40 lines (31 sloc) 1.58 KB
<!DOCTYPE html>
<title>Aeris.js - AMD Example</title>
<link rel="stylesheet" href="../css/example.css"/>
<link rel="shortcut icon" type="image/x-icon" href="../weather.ico"/>
<script type="text/javascript" src="../apikeys.js"></script>
<script type="text/javascript" data-main="src/app" src="bower_components/requirejs/require.js"></script>
<!-- When using Leaflet, make sure to include the Leaflet stylesheet -->
<link rel="stylesheet" href=""/>
<div id="map-canvas"></div>
<div id="loading">Loading...</div>
<div class="prompt">
<h1>Example: Using AMD and Bower.js</h1>
Aeris.js components can all be loaded using an AMD loader (eg. <a href="" target="_blank">Require.js</a>). Take a peek at <code>src/app.js</code> for an example of how to configure Require.js and load Aeris.js AMD modules.
<a href="" target="_blank">Bower.js</a> can be used to automatically download all of the dependencies for Aeris.js. Running <code>bower install</code> from command line will install dependencies in the <code>bower_components</code> directory.
<strong>Having trouble?</strong><br />
Make sure you've created an <code>apikeys.js</code> file, with a valid Aeris <code>client_id</code> and <code>client_secret</code>.<br />
You will also need to run <code>bower install</code> from the <code>examples/amd</code> directory in order to download dependencies for Aeris.js