Also posted at: Falkon, Greasemonkey, Tampermonkey and Violentmonkey.

I think it would be useful to add @nocors metadata block (similarly to @noframes) which would be productive in the sense of coding and consequently make userscript managers to behave in a uniform fashion.

no-www is using GM.xmlHttpRequest which doesn't seem to be supported with all userscript managers.

Example userscript

if (!'www.')) return; // exit (else, continue)

var newURL = location.href.replace('://www.','://');

  method: 'GET',
  url: newURL,
  synchronous: true,
  onprogress: console.log('Checking for no-www...'),
  onload: function(response) {
    if (response.finalUrl == newURL) {
      location.href = newURL;
    } else {
      console.log('Please contact webmaster to remove www.');
  onerror: function(response) {
    console.log('Error requesting for no-www')

If @nocors was introduced, this script could have been shorter.

  .then((response) => {
     if (request.reseponseURL == newURL) {,'_self');