-
-
Notifications
You must be signed in to change notification settings - Fork 670
Figure out how to ship a generated .d.ts with dist files #434
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
Comments
it seems like
|
Unfortunately this doesn't just work with |
Is single file a requirement? If you have an index.ts like this in the source you get an definition index like that using outDir, which pulls in all the other declaration file. The user then only imports the folder and get access to all exports listed in index.ts. By the way, you can have a separate directory for the declaration output files, from where you can easily move them around as an entire folder. |
Closing this issue as part of 2020 vacuum because it has been solved, at least to the extend possible without pulling in additional dependencies, and seems to work well enough. |
For others who get here without having found the solution elsewhere: https://www.assemblyscript.org/compiler.html#command-line-options Either use the Hope that saves someone else some time =] Awesome project, kudos to those involved |
Files in dist are just build artifacts with a source map currently but don't come with pre-generated type definitions, which would eliminate the need to ship the full sources with an eventual npm package. Challenge here is that while
tsc
is able to generate definitions along a compile step, it splits these up into multiple files so these need to be combined somehow, and possibly wrapped with something commonjs to "just work".The text was updated successfully, but these errors were encountered: