Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve the coverage of the README (#995) #1000

Merged
merged 7 commits into from Apr 20, 2020

Conversation

KasparEtter
Copy link
Contributor

@cspotcode
Copy link
Collaborator

Thanks, I made a bunch of tweaks, reverted unrelated formatting changes.

Re the behavior of --script-mode when the script is a symlink, we should figure out if that behavior is intentional or a bug. Better to iron that out first, than to potentially state that a bug is intended via our README.

Copy link
Contributor Author

@KasparEtter KasparEtter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your "review". I left some comments and trust that you take it from here (and see that this gets merged). 🙂 This improved README would have helped me a lot.

Most options can be specified by a `"ts-node"` object in `tsconfig.json` using their programmatic, camelCase names. For example, to enable `--transpile-only`:

```json
// tsconfig.json
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strictly speaking, comments are not allowed in JSON. Given the context is given in the line above, we could/should skip this here.

* `readFile`: Custom TypeScript-compatible file reading function
* `fileExists`: Custom TypeScript-compatible file existence function

### Options via tsconfig.json
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I intentionally had this without a title in the CLI and Programmatic Options section as my understanding is that this only applies to those options (but not the CLI-only or programmatic-only options). Now we are mixing with the titles and sections what options are available and how to provide them. But given that neither approach is perfect, just do you what you think is best.

* `--version` Prints version information
* `-h, --help` Prints the help text
* `-v, --version` Prints the version. `-vv` prints node and typescript compiler versions, too
* `-s, --script-mode` Resolve config relative to the directory of the passed script instead of the current directory. Changes default of `--dir`
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resolve -> Resolves for consistency

@KasparEtter
Copy link
Contributor Author

Re the behavior of --script-mode when the script is a symlink, we should figure out if that behavior is intentional or a bug.

I leave it to you whether you want to create a new issue for this or not. Progress on this would be appreciated, though. 🤓

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Andrew Bradley's Tasks
Merged to master
Development

Successfully merging this pull request may close these issues.

None yet

2 participants