Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript Rename in the import file

// inside module.js
export {
    function1,
    function2
};

// when you want to use the module
// import in the required file with different name

import { function1 as newName1, function2 as newName2 } from './module.js';
 
PREVIOUS NEXT
Tagged: #javascript #Rename #import #file
ADD COMMENT
Topic
Name
7+9 =