Migration guide - Aladin Lite v3 beta

API

We tried as much as possible to be bcak-compatible with v2 API. Should you find an issue in v3 with a code working in v2, please let us know.

Initialization

The main change is in the embedding code and in the initialization sequence. In Aladin Lite version 3, here is the typical code to embed in a web page:

<script type="text/javascript" src="https://code.jquery.com/jquery-1.12.1.min.js" charset="utf-8"></script>
<script type="text/javascript" src="https://aladin.u-strasbg.fr/AladinLite/api/v3/latest/aladin.js" charset="utf-8"></script>

<div id="aladin-lite-div" style="width: 500px; height: 400px"></div>

<script type="text/javascript">
    let aladin;
    A.init.then(() => {
        aladin = A.aladin('#aladin-lite-div', {survey: '2MASS/J', fov: 360, fullScreen: true, cooFrame: 'galactic'});
        aladin.setProjection('AIT');
    });
</script>
Look at this page for a live example.

The Aladin Lite CSS file is no longer loaded explicitely, it is embedded in the JS file.


Submit feedback and bug reports

Submit your feedback by e-mail to thomas.boch at astro.unistra.fr and matthieu.baumann at astro.unistra.fr with a subject starting with [Aladin Lite v3 beta test].