We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1f58d63 commit 0631795Copy full SHA for 0631795
bin/brain-games.js
@@ -1,6 +1,6 @@
1
#!/usr/bin/env node
2
3
-import { getName } from '../src/cli.js';
+import getName from '../src/cli.js';
4
5
getName();
6
console.log('Welcome to the Brain Games!');
src/cli.js
@@ -1,6 +1,8 @@
import readlineSync from 'readline-sync';
-export const getName = () => {
+const getName = () => {
const name = readlineSync.question('May I have your name? ');
console.log(`Hello, ${name}!`);
};
7
+
8
+export default getName;
0 commit comments