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

Add support for ".cts" and ".mts" files #249

Open
cowwoc opened this issue Jul 4, 2023 · 1 comment
Open

Add support for ".cts" and ".mts" files #249

cowwoc opened this issue Jul 4, 2023 · 1 comment

Comments

@cowwoc
Copy link

cowwoc commented Jul 4, 2023

Please update the code to accept ".cts" and ".mts" files as discussed at microsoft/TypeScript#27957 (comment)

Currently, I am getting the following error:

ERROR: Unable to parse C:\Users\Gili\Documents\requirements.js\src\ArrayAsserter.mts: Unexpected token, expected "from" (2:0)

in a project that used to work just fine when the extension was .ts. I cannot use a .ts extension for reasons discussed in that other GitHub ticket.

Thank you.

@cowwoc
Copy link
Author

cowwoc commented Jul 4, 2023

As a workaround, I configured my build script to copy all .mts files into a temporary directory, rename their extension to .ts and run better-docs against the temporary directory. This works fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant