"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const express_1 = __importDefault(require("express"));
const next_1 = __importDefault(require("next"));
const url_1 = require("url");
const path_1 = __importDefault(require("path"));
const dev = process.env.NODE_ENV !== "production";
const app = next_1.default({ dev, dir: path_1.default.join(__dirname, "../../src/client") });
const handle = app.getRequestHandler();
exports.router = express_1.default.Router();
app.prepare().then(() => {
    exports.router.get("*", (req, res) => {
        const parsedUrl = url_1.parse(req.url, true);
        return handle(req, res, parsedUrl);
    });
});
//# sourceMappingURL=NextApp.js.map