UNPKG

nx-ngrok

Version:
2 lines (1 loc) 953 B
var i=Object.defineProperty;var c=Object.getOwnPropertyDescriptor;var f=Object.getOwnPropertyNames;var u=Object.prototype.hasOwnProperty;var d=(e,t)=>{for(var r in t)i(e,r,{get:t[r],enumerable:!0})},j=(e,t,r,p)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of f(t))!u.call(e,o)&&o!==r&&i(e,o,{get:()=>t[o],enumerable:!(p=c(t,o))||p.enumerable});return e};var v=e=>j(i({},"__esModule",{value:!0}),e);var x={};d(x,{update:()=>T});module.exports=v(x);var s=require("@nrwl/devkit");async function T(e){(0,s.getProjects)(e).forEach((r,p)=>{let o=!1;Object.entries(r.targets??{})?.forEach(([a,n])=>{if(n.executor==="nx-ngrok:tunnel"&&Object.prototype.hasOwnProperty.call(n.options,"serverTarget")){let l=n.options.serverTarget;r.targets?.[a].options.serverTarget&&(o=!0,delete r.targets[a].options.serverTarget,r.targets[a].options.target=l)}}),o&&(0,s.updateProjectConfiguration)(e,p,r)}),await(0,s.formatFiles)(e)}0&&(module.exports={update});