chore: implement basic devServer

This commit is contained in:
Igor Randjelovic
2021-03-26 22:16:36 +01:00
parent bb23bca3ce
commit 75e6009b8a
7 changed files with 198 additions and 58 deletions

View File

@ -1,4 +1,5 @@
import dedent from 'ts-dedent';
import { env } from "@nativescript/webpack";
// de-indents strings so multi-line string literals can be used
function cleanup(data: any[]) {
@ -28,7 +29,9 @@ export function warn(...data: any): void {
}
export function info(...data: any): void {
console.log(`[@nativescript/webpack] Info: \n`, ...cleanup(data));
if(env.verbose) {
console.log(`[@nativescript/webpack] Info: \n`, ...cleanup(data));
}
}
// todo: refine