I have this `js` file:

**test.js**:

```
const axios = require('axios');

console.log('test');

```

I have installed dependencies by running

```
npm install

```

My folder structure looks like this:

```
test
  node_modules
  package.json
  package-lock.json
  test.js

```

If I remove the first line `const axios = require('axios');`, and run:

```
nodejs test.js

```

it runs fine and prints `test`.

However if the first line is present, I get this error:

```
/home/username/test/node_modules/axios/index.js:1
import axios from './lib/axios.js';
       ^^^^^

SyntaxError: Unexpected identifier

```

How do I fix it?

PS

```
node -v
v18.4.0

nodejs -v
v10.19.0

npm -v
8.12.1

```