Uncaught ReferenceError: require is not defined a code example Example: require is not defined remove "type": "module" from package.json