Skip to content


Choose a tag to compare
@jaredpalmer jaredpalmer released this 29 Dec 16:01
· 289 commits to master since this release


  • Add success/failure flags
  • Add transpileOnly flag
  Rebuilds on any change

  $ tsdx watch [options]

  -i, --entry           Entry module(s)
  --target              Specify your target environment  (default web)
  --name                Specify name exposed in UMD builds
  --format              Specify module format(s)  (default cjs,esm)
  --tsconfig            Specify your custom tsconfig path (default <root-folder>/tsconfig.json)
  --verbose             Keep outdated console output in watch mode instead of clearing the screen
+  --onFirstSuccess      Run a command on the first successful build
+  --onSuccess           Run a command on a successful build
+  --onFailure           Run a command on a failed build
  --noClean             Don't clean the dist folder
+  --transpileOnly       Skip type checking
  -h, --help            Displays this message

  $ tsdx watch --entry src/foo.tsx
  $ tsdx watch --target node
  $ tsdx watch --name Foo
  $ tsdx watch --format cjs,esm,umd
  $ tsdx watch --tsconfig ./
  $ tsdx watch --noClean
+  $ tsdx watch --onFirstSuccess "echo The first successful build!"
+  $ tsdx watch --onSuccess "echo Successful build!"
+  $ tsdx watch --onFailure "The build failed!"
+  $ tsdx watch --transpileOnly


  • Fixed jest watch mode


  • (refactor): invert if in run function (#404) e1370de
  • (optim/test): use node testEnvironment (#405) ec0f285
  • (clean): remove --env=jsdom as JSDOM is Jest's default (#396) 7c79b74
  • (format): alphabetize package.json deps (#398) 27ba1dd
  • (docs/fix): fix ToC changes / bugs introduced in #307 (#397) 387f3c2
  • (docs): improve test watch mode docs (#395) 531010e
  • Update @types/node to the latest version 🚀 (#391) be3c410
  • [docs] howto turn off watch mode (#385) efb3539
  • feat: Add success/failure hooks to watch (#130) ab54278
  • (types/fix): explicit Rollup typing, fix treeshake location (#371) 2a5e5a5
  • feat: Add transpileOnly flag to watch and build command (#307) ee4b307