From 2af099fe9c24286a550fd5cce502b3ba43b858d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Standa=20Luke=C5=A1?= Date: Sun, 22 Aug 2021 20:36:45 +0000 Subject: [PATCH] Add a MSBuild task for running `yarn build` In case yarn is not installed, npm is used. Yarn is preferred, because it takes less time to run it, so it's less annoying. The Target only runs when any typescript file is changed, otherwise it's skipped by MSBuild In case there are some JS error, the build should continue normally, so hopefully it won't cause some build issues This should solve the problem that we forget to build the JS and then something does not work. And when someone clones the repo, it just won't compile because the JS files are missing --- src/DotVVM.Framework/DotVVM.Framework.csproj | 28 ++++++++++++++++++++ src/DotVVM.Framework/rollup.config.js | 2 -- 2 files changed, 28 insertions(+), 2 deletions(-) diff --git a/src/DotVVM.Framework/DotVVM.Framework.csproj b/src/DotVVM.Framework/DotVVM.Framework.csproj index f9c2fd0a7b..2a744467ea 100644 --- a/src/DotVVM.Framework/DotVVM.Framework.csproj +++ b/src/DotVVM.Framework/DotVVM.Framework.csproj @@ -128,4 +128,32 @@ $(DefineConstants);RELEASE + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/DotVVM.Framework/rollup.config.js b/src/DotVVM.Framework/rollup.config.js index cbd8d74fb7..cb9d64a267 100644 --- a/src/DotVVM.Framework/rollup.config.js +++ b/src/DotVVM.Framework/rollup.config.js @@ -1,7 +1,6 @@ import typescript from '@rollup/plugin-typescript' import resolve from 'rollup-plugin-node-resolve'; import commonjs from 'rollup-plugin-commonjs'; -import livereload from 'rollup-plugin-livereload'; import { terser } from 'rollup-plugin-terser' import replace from '@rollup/plugin-replace'; @@ -79,7 +78,6 @@ const config = ({ minify, input, output, spa, legacy }) => ({ ascii_only: true } }), - //!production && livereload('public') ] })