Commit 1b5c9591 authored by 鍛ㄦ眽鎴's avatar 鍛ㄦ眽鎴 Committed by Ren茅e Kooi
Browse files

Init bankai after mkdirp (#489)

This is a 馃悰 

When I was trying to add the faviconTag to the document I found this bug. I created a `faviconNode`, called `createEdge()` inside it, then the graph's change event was emited, then it [emits the compiler's change event]( immediately, but at this moment, [compiler's change event]( has not yet been listened.

<!-- Provide a general summary of the changes in the title above -->

## Checklist
<!-- Remove items that do not apply. For completed items, change [ ] to [x]. -->
- [x] tests pass
- [ ] tests and/or benchmarks are included
- [ ] documentation is changed or added

## Context

## Semver Changes
parent f894c981
......@@ -20,16 +20,18 @@ function build (entry, outdir, opts) {
watch: false,
base: opts.base
var compiler = bankai(entry, bankaiOpts)
var log = compiler.log
if (!outdir) {
outdir = path.join(compiler.dirname, 'dist')
var dirname = path.extname(entry) === '' ? entry : utils.dirname(entry)
outdir = path.join(dirname, 'dist')
mkdirp(outdir, function (err) {
if (err) return console.error(err)
var compiler = bankai(entry, bankaiOpts)
var log = compiler.log'Compiling & compressing files\n')
created(compiler.dirname, outdir + '/')
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment