@nestjs/schematics
Advanced tools
Comparing version 6.1.2-next to 6.1.3-next
@@ -47,3 +47,3 @@ "use strict"; | ||
name: options.directory, | ||
version: '7.0.0', | ||
version: '^7.0.0', | ||
}); | ||
@@ -50,0 +50,0 @@ } |
@@ -74,3 +74,3 @@ import { strings } from '@angular-devkit/core'; | ||
name: options.directory, | ||
version: '7.0.0', | ||
version: '^7.0.0', | ||
}); | ||
@@ -77,0 +77,0 @@ } |
@@ -16,6 +16,2 @@ import { Injectable } from '@nestjs/common'; | ||
} | ||
public getClientDirPath(options: AngularModuleOptions): string { | ||
return join(process.cwd(), '..', options.rootPath); | ||
} | ||
} |
@@ -17,8 +17,10 @@ import { Injectable } from '@nestjs/common'; | ||
); | ||
const clientPath = this.getClientDirPath(options); | ||
const clientPath = options.rootPath; | ||
const indexFilePath = this.getIndexFilePath(clientPath); | ||
app.use(express.static(clientPath, options.serveStaticOptions)); | ||
app.get(options.renderPath, (req, res) => res.sendFile(indexFilePath)); | ||
app.get(options.renderPath, (req: any, res: any) => | ||
res.sendFile(indexFilePath), | ||
); | ||
} | ||
} |
@@ -20,3 +20,3 @@ import { Injectable } from '@nestjs/common'; | ||
options.serveStaticOptions || ({} as any); | ||
const clientPath = this.getClientDirPath(options); | ||
const clientPath = options.rootPath; | ||
const indexFilePath = this.getIndexFilePath(clientPath); | ||
@@ -30,3 +30,3 @@ | ||
}); | ||
app.get(options.renderPath, (req, res) => { | ||
app.get(options.renderPath, (req: any, res: any) => { | ||
const stream = fs.createReadStream(indexFilePath); | ||
@@ -33,0 +33,0 @@ res.type('text/html').send(stream); |
{ | ||
"name": "@nestjs/schematics", | ||
"version": "6.1.2-next", | ||
"version": "6.1.3-next", | ||
"description": "Nest - modern, fast, powerful node.js web framework (@schematics)", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
175835
5123