Skip to main content

JavaScript Question 134

Question 134 of 0JavaScript

How can we invoke `sum` in `sum.js` from `index.js?`

Login Required

Please login to select answers and solve this question. You can view the question without logging in.

Code:
// sum.js
export default function sum(x) {
  return x + x;
}

// index.js
import * as sum from './sum';

Select the correct option: