ÿØÿà JFIF ÿá Exif MM * ÿÛ C
Server IP : 199.250.214.225 / Your IP : 18.226.187.194 Web Server : Apache System : Linux vps64074.inmotionhosting.com 3.10.0-1160.105.1.vz7.214.3 #1 SMP Tue Jan 9 19:45:01 MSK 2024 x86_64 User : nicngo5 ( 1001) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : OFF Directory : /home/nicngo5/funds.upgrade.nicn.gov.ng/funds-upgraded/node_modules/webpack-dev-server/lib/utils/ |
Upload File : |
'use strict'; const { join } = require('path'); const { createReadStream } = require('graceful-fs'); const clientBasePath = join(__dirname, '..', '..', 'client'); function routes(server) { const app = server.app; const middleware = server.middleware; app.get('/__webpack_dev_server__/sockjs.bundle.js', (req, res) => { res.setHeader('Content-Type', 'application/javascript'); createReadStream( join(clientBasePath, 'modules/sockjs-client/index.js') ).pipe(res); }); app.get('/webpack-dev-server/invalidate', (_req, res) => { server.invalidate(); res.end(); }); app.get('/webpack-dev-server', (req, res) => { middleware.waitUntilValid((stats) => { res.setHeader('Content-Type', 'text/html'); res.write( '<!DOCTYPE html><html><head><meta charset="utf-8"/></head><body>' ); const statsForPrint = typeof stats.stats !== 'undefined' ? stats.toJson().children : [stats.toJson()]; res.write(`<h1>Assets Report:</h1>`); statsForPrint.forEach((item, index) => { res.write('<div>'); const name = item.name || (stats.stats ? `unnamed[${index}]` : 'unnamed'); res.write(`<h2>Compilation: ${name}</h2>`); res.write('<ul>'); const publicPath = item.publicPath === 'auto' ? '' : item.publicPath; for (const asset of item.assets) { const assetName = asset.name; const assetURL = `${publicPath}${assetName}`; res.write( `<li> <strong><a href="${assetURL}" target="_blank">${assetName}</a></strong> </li>` ); } res.write('</ul>'); res.write('</div>'); }); res.end('</body></html>'); }); }); } module.exports = routes;