We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
When I use /// <reference path="..." /> to refer to typescript source files, I want those files to be concatenated in the output .js file.
/// <reference path="..." />
.js
The text was updated successfully, but these errors were encountered:
Allow refs as strings, passed to compile (See #2)
96e5a45
@dlee,
This module isn't meant to read any files, it's just meant to take a string of TypeScript and output a string of JavaScript.
But, would this suffice?
/** * Compile a string of TypeScript, return as a string of JavaScript * * @param {String} input - TypeScript to compile * @param {Object} [refs] - map of referenced filenames to content * @return {String} JavaScript output * @throws TypeScript compile error */ ts.compile('/// <reference path="foo.ts" />', { 'foo.ts': 'var bar = 123;' });
This would make the user responsible for loading the files into memory as strings, then passing all of the content to compile.
compile
This is implemented now on the master branch. Let me know if it works for you.
Sorry, something went wrong.
Thanks! I think that would work.
No branches or pull requests
When I use
/// <reference path="..." />
to refer to typescript source files, I want those files to be concatenated in the output.js
file.The text was updated successfully, but these errors were encountered: