@tsonic/nodejs 10.0.39 → 10.0.41

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -15,7 +15,7 @@ Use `@tsonic/nodejs` when you want Node-like modules (`fs`, `path`, `events`, `c
15
15
 
16
16
  ```bash
17
17
  mkdir my-app && cd my-app
18
- npx --yes tsonic@latest init --surface nodejs
18
+ npx --yes tsonic@latest init --surface @tsonic/js
19
19
  npx --yes tsonic@latest add npm @tsonic/nodejs
20
20
  ```
21
21
 
@@ -37,14 +37,11 @@ npm run dev
37
37
  ## Existing project
38
38
 
39
39
  ```bash
40
+ npx --yes tsonic@latest init --surface @tsonic/js
40
41
  npx --yes tsonic@latest add npm @tsonic/nodejs
41
42
  ```
42
43
 
43
- If the workspace is not already Node surface, set:
44
-
45
- ```bash
46
- npx --yes tsonic@latest init --surface nodejs
47
- ```
44
+ `@tsonic/nodejs` is a regular package, not a surface. Use `@tsonic/js` for the ambient JavaScript world, and add `@tsonic/nodejs` when you want `node:*` module imports.
48
45
 
49
46
  ## Versioning
50
47
 
@@ -116,7 +113,7 @@ import { http } from "@tsonic/nodejs/nodejs.Http.js";
116
113
 
117
114
  ## Imports (important)
118
115
 
119
- For `--surface nodejs` projects, prefer Node-style imports:
116
+ For JS-surface projects with `@tsonic/nodejs` installed, prefer Node-style imports:
120
117
 
121
118
  - `node:fs`, `node:path`, `node:crypto`, `node:process`, ...
122
119
  - bare aliases (`fs`, `path`, `crypto`, ...) are also supported