Need assistance in Understand the Differences Between import and require

Challenge Name

Understand the Differences Between import and require has an issue.

Issue Description

Browser Information

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36.

Screenshot

Your Code


import { capitalizeString } from "string_functions";
capitalizeString("hello!");

You’ve done it right. This seems like a bug.

Yes it’s a bug. But if you or anyone else want to pass the test then adding following code works for me.

import { capitalizeString } from "string_functions"

The solution on the “Hint” page is incorrect.

The hyphen should be an underscore.

"string-functions"

should be

"string_functions"

Also, the code window would benefit from:

/* Alter code below this line */

/* Alter code above this line */