Open
Description
openedon Jan 10, 2018
To use the Node API, you need to create a compiler:
// Spawn a worker with the specified options.
const compiler = Haul.create({
platform: 'android',
context: process.cwd(),
production: false,
minify: false,
bundle: false,
port: 3021,
config: require('./haul.config.js'),
});
// Trigger a build
compiler.build()
.map(result => match (result.type) {
'success': `Bundle built in ${result.duration}`,
'error': `Failed to build bundle`,
else: null,
})
.filter(Boolean)
.subscribe(console.log);
// Symbolicate
compiler.symbolicate(frames)
.subscribe(result => console.log(result.stack));
// Kill the server and cleanup
compiler.destroy();
This issue assumes that #287 is done.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment