url.js (476B)
1 /* -*- Mode: js; js-indent-level: 2; -*- */ 2 /* 3 * Copyright 2011 Mozilla Foundation and contributors 4 * Licensed under the New BSD license. See LICENSE or: 5 * http://opensource.org/licenses/BSD-3-Clause 6 */ 7 "use strict"; 8 9 // Note: This file is overridden in the 'package.json#browser' field to 10 // substitute lib/url-browser.js instead. 11 12 // Use the URL global for Node 10, and the 'url' module for Node 8. 13 module.exports = typeof URL === "function" ? URL : require("url").URL;