Navigation for the ZIM JavaScript Canvas Framework

AboutExamplesLearnEditorCodeDocsDevsGold
JavaScript 6

ES6 WITH ZIM

You can code ZIM with ES6 (JavaScript 6). See an EXAMPLE page.
collect Plasma Points for the Plasma Points mobile app with ZIM!

ES6 MODULES



ES6 Modules can be imported for ZIM and helper libraries. See the IMPORT examples. (The imports include CreateJS as well.)
    <script type="module">
    
    // note the type="module" in the script tag above    
    // alternatively, use script tags - see https://zimjs.com/script
    
    import zim from "https://zimjs.com/cdn/016/zim";
        
    new Frame(FIT, 1024, 768, light, dark, ready);
    function ready() {
            
        // put your code here
        
        new Circle(100, blue).center().drag();
        
    }
    
    </script>
There modules for the following libraries. Each of these includes ZIM and CreateJS. See the IMPORT examples.
    // USE ANY OF THESE (or combinations):

    // REGULAR
    import zim from "https://zimjs.com/cdn/016/zim";
        
    // GAME
    // for ZIM plus game module
    import zim from "https://zimjs.com/cdn/016/zim_game";

    // PHYSICS
    // for ZIM plus Box2D plus physics module and game module
    import zim from "https://zimjs.com/cdn/016/zim_physics";

    // SOCKET 
    // Must also include a script tag above with 
    // <script src=https://zimjs.org/cdn/2.3.0/socket.io.js></script>
    import zim from "https://zimjs.com/cdn/016/zim_socket";

    // THREEJS
    // for ZIM plus three module and three.js 
    // and OrbitControls FirstPersonControls and GLTFLoader
    import zim, from "https://zimjs.com/cdn/016/zim_three";

    // CAM
    // for ZIM plus cam module
    import zim from "https://zimjs.com/cdn/016/zim_cam";

    // PIZZAZZ
    // for ZIM plus pizzazz modules 1, 2, 3 
    import zim from "https://zimjs.com/cdn/016/zim_pizzazz";

    // TEST
    // for unminified ZIM (better error messages)
    import zim from "https://zimjs.com/cdn/016/zim_test";

    // LOCAL
    // for local versions of a module add the .js extension
    import zim from "local/zim.js";   
    
Or you can use SCRIPT TAGS or NPM.