RebelMouse Talk to Us
JS error: "ReferenceError: require is not defined"

If you get a JS error "ReferenceError: require is not defined"

All you need to do is  use " {{require}} " instead of "require" in your code, and the error should be resolved.

 

In order to do that you need to :

1.From left menu go to Layout & design 

[rebelmouse-proxy-image https://media.rbl.ms/image?u=%2Fmedia.forumbee.com%2Fi%2Fe4a6fa4f-894c-47a2-83ee-640f78e66b16%2F547.png&ho=https%3A%2F%2Fs3-us-west-2.amazonaws.com&s=938&h=d5b73d617990058b0b26851345fd0ebbb84136cf1b9e81a8af8b6e7414654280&size=980x&c=1180410140 crop_info="%7B%22image%22%3A%20%22https%3A//media.rbl.ms/image%3Fu%3D%252Fmedia.forumbee.com%252Fi%252Fe4a6fa4f-894c-47a2-83ee-640f78e66b16%252F547.png%26ho%3Dhttps%253A%252F%252Fs3-us-west-2.amazonaws.com%26s%3D938%26h%3Dd5b73d617990058b0b26851345fd0ebbb84136cf1b9e81a8af8b6e7414654280%26size%3D980x%26c%3D1180410140%22%7D" expand=1]

 

2.From design page -> go to the post page section 

[rebelmouse-proxy-image https://media.rbl.ms/image?u=%2Fmedia.forumbee.com%2Fi%2F52b776d7-db0f-4e23-895e-f5540ee76848%2F547.png&ho=https%3A%2F%2Fs3-us-west-2.amazonaws.com&s=230&h=bf40707bb3cc7c6a6a75d15d3a406eff6f379153922436b5c75009d3e017a887&size=980x&c=2376540116 crop_info="%7B%22image%22%3A%20%22https%3A//media.rbl.ms/image%3Fu%3D%252Fmedia.forumbee.com%252Fi%252F52b776d7-db0f-4e23-895e-f5540ee76848%252F547.png%26ho%3Dhttps%253A%252F%252Fs3-us-west-2.amazonaws.com%26s%3D230%26h%3Dbf40707bb3cc7c6a6a75d15d3a406eff6f379153922436b5c75009d3e017a887%26size%3D980x%26c%3D2376540116%22%7D" expand=1]

 

3.Pick the section where you have the code that uses "require" from here

[rebelmouse-proxy-image https://media.rbl.ms/image?u=%2Fmedia.forumbee.com%2Fi%2Ff146959b-12af-40c5-86cb-fa098582b340%2F547.png&ho=https%3A%2F%2Fs3-us-west-2.amazonaws.com&s=176&h=fd2696e3941d7bce6052eae8dc60e359dbaebf97cf98a42a53aad1cbbfdb3b2c&size=980x&c=3139785841 crop_info="%7B%22image%22%3A%20%22https%3A//media.rbl.ms/image%3Fu%3D%252Fmedia.forumbee.com%252Fi%252Ff146959b-12af-40c5-86cb-fa098582b340%252F547.png%26ho%3Dhttps%253A%252F%252Fs3-us-west-2.amazonaws.com%26s%3D176%26h%3Dfd2696e3941d7bce6052eae8dc60e359dbaebf97cf98a42a53aad1cbbfdb3b2c%26size%3D980x%26c%3D3139785841%22%7D" expand=1]

 

4.From the code section of the widget, you can update it and replace it by " {{require}} "

[rebelmouse-proxy-image https://media.rbl.ms/image?u=%2Fmedia.forumbee.com%2Fi%2Fba87f298-0c46-431e-aca2-b4be2b70c879%2F547.png&ho=https%3A%2F%2Fs3-us-west-2.amazonaws.com&s=116&h=9ae56e73617a2cff20345b7fd1f5c356aaefc83b5dd1ddd42da7ae397ca380e4&size=980x&c=661122888 crop_info="%7B%22image%22%3A%20%22https%3A//media.rbl.ms/image%3Fu%3D%252Fmedia.forumbee.com%252Fi%252Fba87f298-0c46-431e-aca2-b4be2b70c879%252F547.png%26ho%3Dhttps%253A%252F%252Fs3-us-west-2.amazonaws.com%26s%3D116%26h%3D9ae56e73617a2cff20345b7fd1f5c356aaefc83b5dd1ddd42da7ae397ca380e4%26size%3D980x%26c%3D661122888%22%7D" expand=1]

 

5.After the change has done -> click save  and you update will take effect

[rebelmouse-proxy-image https://media.rbl.ms/image?u=%2Fmedia.forumbee.com%2Fi%2F4b6d2102-2f71-4c01-9c38-55dc3ddeec0f%2F547.png&ho=https%3A%2F%2Fs3-us-west-2.amazonaws.com&s=472&h=0152c080ef422ed415309fd1f1a31c6b1d00facf5399ef48f3eaf9111220080a&size=980x&c=1157888309 crop_info="%7B%22image%22%3A%20%22https%3A//media.rbl.ms/image%3Fu%3D%252Fmedia.forumbee.com%252Fi%252F4b6d2102-2f71-4c01-9c38-55dc3ddeec0f%252F547.png%26ho%3Dhttps%253A%252F%252Fs3-us-west-2.amazonaws.com%26s%3D472%26h%3D0152c080ef422ed415309fd1f1a31c6b1d00facf5399ef48f3eaf9111220080a%26size%3D980x%26c%3D1157888309%22%7D" expand=1]

 

Build on a Better PlatformReady to See More?
Request a Proposal
Learn More About RebelMouse’s High-Performing Infrastructure
Featured

Learn More About RebelMouse’s High-Performing Infrastructure

To ensure every site powered by RebelMouse is high performing, secure, and optimized for user experience, we only use the best and most reliable methods to host our infrastructure. Here's a detailed look at some of the services and security measures we use every day to secure maximum stability and security for each of our sites.

Keep reading... Show less
Build on a Better PlatformReady to See More?
Request a Proposal
An Important Note on Site Quality From Google’s Search Expert
Rebel Insights

An Important Note on Site Quality From Google’s Search Expert

Do you ever wonder if a few typos can impact your site’s search performance? According to Google’s Search Advocate John Mueller, it takes more than just a few grammatical missteps for Google’s crawler to determine your site’s quality.

During a New Year’s Eve Office Hours hangout, Mueller said that if certain portions of a website are deemed low quality, it can negatively impact the site’s search ranking overall. A good example of this is a site that has different language versions within the same domain. If the site has a French-language version that is made up of quality content, but the English translation isn’t up to the same standard, the ranking of the French version of the site could be negatively impacted.

Keep reading... Show less
Build on a Better PlatformReady to See More?
Request a Proposal