From 5abc45871eca6cf2d38189f28a34016c5881d1fd Mon Sep 17 00:00:00 2001 From: Chi-Hsuan Huang Date: Wed, 13 Apr 2022 12:06:34 +0800 Subject: [PATCH] Updated How to set up WooCommerce development environment (markdown) --- How-to-set-up-WooCommerce-development-environment.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/How-to-set-up-WooCommerce-development-environment.md b/How-to-set-up-WooCommerce-development-environment.md index fae0dce..3173f09 100644 --- a/How-to-set-up-WooCommerce-development-environment.md +++ b/How-to-set-up-WooCommerce-development-environment.md @@ -234,7 +234,15 @@ There are a number of helper scripts exposed via our `package.json` and `project - `pnpm nx lint woocommerce-admin` : Run eslint over the javascript files and stylelint over scss files - `pnpm nx test woocommerce-admin` : Run the JS test suite - - `pnpm run ts:check woocommerce-admin`: Runs the tsc check over typescript files. + +### Typescript + +The `pnpm nx ts:check woocommerce-admin` command will check your TypeScript files for errors, and has been added to `.vscode/tasks.json`. +Running this task in vscode will highlight the errors in your editor file navigator. + +If you allow the `npm nx ts:check:watch woocommerce-admin` command to run automatically as configured, it will run in the background and pick up any errors as you save the files. +Note: Even if you don't run this task, the IDE uses its language server to pick up type errors in files that are open. This is only necessary for picking up errors +across the entire repository even when they haven't been opened in the IDE. ## Debugging