8 } = require('fuse-box');
9 // const transformInferno = require('../../dist').default
10 const transformInferno = require('ts-transform-inferno').default;
11 const transformClasscat = require('ts-transform-classcat').default;
13 let isProduction = false;
15 Sparky.task('config', _ => {
19 output: 'dist/$name.js',
20 experimentalFeatures: true,
22 sourceMaps: !isProduction,
24 before: [transformClasscat(), transformInferno()],
27 EnvPlugin({ NODE_ENV: isProduction ? 'production' : 'development' }),
30 title: 'Inferno Typescript FuseBox Example',
31 template: 'src/index.html',
32 path: isProduction ? "/static" : "/"
36 bakeApiIntoBundle: 'app',
42 app = fuse.bundle('app').instructions('>index.tsx');
44 Sparky.task('clean', _ => Sparky.src('dist/').clean('dist/'));
45 Sparky.task('env', _ => (isProduction = true));
46 Sparky.task('copy-assets', () => Sparky.src('assets/*.ico').dest('dist/'));
47 Sparky.task('dev', ['clean', 'config', 'copy-assets'], _ => {
52 Sparky.task('prod', ['clean', 'env', 'config', 'copy-assets'], _ => {
53 // fuse.dev({ reload: true }); // remove after demo