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

Can the compile method return a map? #38

Open
justinwyllie opened this issue Jun 10, 2016 · 0 comments
Open

Can the compile method return a map? #38

justinwyllie opened this issue Jun 10, 2016 · 0 comments

Comments

@justinwyllie
Copy link

Running this from the command line I can pass the -m flag and it will produce a source map. e.g. cjsx -cm will produce both the .js file and the source map file.

However; running this in a node (in fact Jest) context I want to do:

const coffeereact = require('coffee-react');
var compiled = coffeereact.compile(src, {bare: true, map: true});

And have complied have both the compiled JS code and the source map. I want to do this so I can write the source map to the file system for later use.

At the moment putting the map: true option in this context seems to have no effect.

I'm not sure if this is possible? Or if not - perhaps this is a feature request?

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