matias bravo
PreguntaEjectuo el mismo codigo que el profesor pero me sale:
Alguien sabe como puedo solucionarlo?
(node:4936) Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension. (Use `node --trace-warnings ...` to show where the warning was created) /Users/macbook/Desktop/Programacion/JavaScript/Ecma/src/es6/tempCodeRunnerFile.js:1 import hello from './module.mjs' ^^^^^^ SyntaxError: Cannot use import statement outside a module
matias bravo
Finalmente tuve que ejecutarlo de otra manera para que funcionara.
Codigo incial
export default hello; - import hello from './module'; hello()
Codigo final
module.exports = hello - const hello = require('./module') console.log(hello())```

Mauro Nava
Puedes mostraar tu codigo?