import : import : Global JAVASCRIPT TUTORIALS


JAVASCRIPT TUTORIALS » Global » import »

 

import







The import keyword allows a script to import properties, functions, and objects from a signed script that has exported the information.












<html>
    <body>
    <script language = "JavaScript">
    <!--
    // imports the variables name, city and state from another script.
    // This makes those properties accessible to myObj.

    import myObj.name;
    import myObj.city;
    import myObj.state;
    -->
    </script>
    </body>
    </html>







HTML code for linking to this page:

Follow Navioo On Twitter

JAVASCRIPT TUTORIALS

 Navioo Global
» import