Web Performance
Requirements
- You need to have the latest version of Node. Preferably, you're using 9.8.0, but the latest LTS should work as well.
- You should have
npx
installed usingnpm install -g npx
. - Install the React Developer Tools.
const path = require('path') | |
const serverless = require('serverless-http'); | |
const minify = require('html-minifier').minify; | |
const { app } = require("./dist/angular-lambda-ssr/serverless/main"); | |
const handle = serverless(app, { | |
provider: 'aws', | |
type: 'lambda-edge-origin-request' |
import 'zone.js/dist/zone-node'; | |
import { join } from 'path'; | |
import * as fs from 'fs'; | |
import { renderModule, AppServerModule } from './src/main.server'; | |
import * as express from 'express'; | |
export const app = express(); | |
const distFolder = join(process.cwd(), 'dist/angular-lambda-ssr/browser'); |
npx
installed using npm install -g npx
.