@bolttech/server-side-next
Version:
This library was generated with [Nx](https://nx.dev).
3 lines (2 loc) • 1.04 kB
JavaScript
;var e=require("url"),r=require("querystring"),t=function(e){return!(!e||e.includes("cms_page_")||e.includes("deleted")||e.includes("drafts")||e.includes("old")||e.includes("xml")||e.includes("txt")||e.includes("404")||e.includes("500")||e.includes("/content/vouchers"))},n=function(e){return e.replace(/\/\//g,"/")},l=function(e){return e.split("/").map((function(e){return encodeURIComponent(e)})).join("/")};function u(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"http://localhost:3000",l=new e.URL(t,n),u=l.hash,s=l.host,o=l.hostname,a=l.href,c=l.pathname,i=l.port,h=l.protocol,p=l.search,d=l.searchParams;return{auth:null,path:null,slashes:null,hash:u,host:s,hostname:o,href:a,pathname:c,protocol:h,search:p,port:i,query:r.parse(d.toString())}}var s={urlFilter:t,urlMapper:n,urlEncode:l,urlParse:u};exports.default=s,exports.urlEncode=l,exports.urlFilter=t,exports.urlMapper=n,exports.urlParse=u;
//# sourceMappingURL=url.util-0719d39e.js.map