🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Sign inDemoInstall
Socket

ts-node-dev

Package Overview
Dependencies
Maintainers
1
Versions
78
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ts-node-dev - npm Package Compare versions

Comparing version

to
1.0.0-pre.57

8

CHANGELOG.md
### Yalc changelog
## 1.0.0-pre.57 (2020-08-13)
- fix `--deps` flag
- add `--deps-level` flag
- remove setting default NODE_ENV
- add process.env.TS_NODE_DEV = 'true'
## 1.0.0-pre.56 (2020-07-24)

@@ -4,0 +12,0 @@

12

lib/cfg.js

@@ -19,10 +19,9 @@ var fs = require('fs');

|| read(process.env.HOME || process.env.USERPROFILE) || {};
// Truthy == --all-deps, false: one level of deps
if (typeof c.deps !== 'number') c.deps = c.deps ? -1 : 1;
c.deps = parseInt(opts['deps-level']) || 0
if (typeof c.depsLevel === 'number') c.deps = c.depsLevel
if (opts) {
// Overwrite with CLI opts ...
if (opts.allDeps) c.deps = -1;
if (!opts.deps) c.deps = 0;
if (opts['deps'] || opts['all-deps']) c.deps = -1;
if (opts.dedupe) c.dedupe = true;

@@ -33,3 +32,2 @@ if (opts.respawn) c.respawn = true;

}
var ignoreWatch = ([]).concat(opts && opts['ignore-watch'] || []).concat(c.ignore || []);

@@ -36,0 +34,0 @@ opts.debug && console.log('Ignore watch:', ignoreWatch)

@@ -160,3 +160,3 @@ var fork = require('child_process').fork

// Listen for `required` messages and watch the required file.
ipc.on(child, 'required', function (m) {
ipc.on(child, 'required', function (m) {
var isIgnored =

@@ -163,0 +163,0 @@ cfg.ignore.some(isPrefixOf(m.required)) ||

@@ -18,4 +18,5 @@ var path = require('path')

// Set NODE_ENV to 'development' unless already set
if (!process.env.NODE_ENV) process.env.NODE_ENV = 'development'
if (process.env.TS_NODE_DEV === undefined) {
process.env.TS_NODE_DEV = 'true'
}

@@ -22,0 +23,0 @@ if (process.env.NODE_DEV_PRELOAD) {

{
"name": "ts-node-dev",
"version": "1.0.0-pre.56",
"version": "1.0.0-pre.57",
"description": "Compiles your TS app and restarts when files are modified.",

@@ -39,3 +39,3 @@ "keywords": [

"test": "ts-node -T test/index.ts",
"test-dev": "ts-node-dev -T --respawn test/index.ts",
"test-dev": "ts-node-dev -T --respawn test/index.ts --output",
"test-docker": "docker-compose up",

@@ -61,2 +61,3 @@ "ci": "yarn test",

"@types/fs-extra": "^9.0.1",
"@types/minimist": "^1.2.0",
"@types/node": "^8.0.4",

@@ -81,4 +82,4 @@ "@types/tape": "^4.13.0",

"peerDependencies": {
"typescript": "*",
"node-notifier": "*"
"node-notifier": "*",
"typescript": "*"
},

@@ -85,0 +86,0 @@ "peerDependenciesMeta": {

@@ -11,3 +11,2 @@ # ts-node-dev

```

@@ -41,6 +40,4 @@ yarn add ts-node-dev --dev

Look up flags and options can be used [in ts-node's docs](https://github.com/TypeStrong/ts-node#cli-and-programmatic-options).
**Also there are additional options specific to `ts-node-dev`:**

@@ -51,13 +48,14 @@

- use `--deps` to watch `node_modules`, by default watching it turned off.
- `--debug` - Some additional debug output.
- `--interval` - Polling interval (ms)
- `--debounce` - Debounce file change events (ms, non-polling mode)
- `--clear` (`--cls`) Will clear screen on restart
- `--watch` - Explicitly add arbitrary files or folders to watch and restart on change (list separated by commas, [chokidar](https://github.com/paulmillr/chokidar) patterns)
- `--exit-child` - Adds 'SIGTERM' exit handler in a child process.
- `--rs` - Allow to restart with "rs" line entered in stdio, disabled by default.
- `--no-notify` - Do not display desktop-notifications (Notifications are only displayed if `node-notifier` is installed).
* `--debug` - Some additional debug output.
* `--interval` - Polling interval (ms)
* `--debounce` - Debounce file change events (ms, non-polling mode)
* `--clear` (`--cls`) Will clear screen on restart
* `--watch` - Explicitly add arbitrary files or folders to watch and restart on change (list separated by commas, [chokidar](https://github.com/paulmillr/chokidar) patterns)
* `--exit-child` - Adds 'SIGTERM' exit handler in a child process.
* `--rs` - Allow to restart with "rs" line entered in stdio, disabled by default.
* `--no-notify` - Do not display desktop-notifications (Notifications are only displayed if `node-notifier` is installed).
If you need to detect that you are running with `ts-node-dev`, check if `process.env.TS_NODE_DEV` is set.
**Desktop Notifications**

@@ -64,0 +62,0 @@

Sorry, the diff of this file is not supported yet