yeoman/generator-webapp

build bug Cause file content to be emptied

3lang3 opened this issue · 3 comments

yo webapp
create a new empty html file (eg: test.html)
run gulp build
Cause index.html content to be emptied
error:

events.js:183
      throw er; // Unhandled 'error' event
      ^

TypeError: First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.
    at Function.Buffer.from (buffer.js:202:9)
    at new Buffer (buffer.js:158:17)
    at DestroyableTransform._transform (H:\CompanyJob\pcbcart_html_cn\node_modules\wiredep\wiredep.js:136:23)
    at DestroyableTransform.Transform._read (H:\CompanyJob\pcbcart_html_cn\node_modules\readable-stream\lib\_stream_transform.js:184:10)
    at DestroyableTransform.Transform._write (H:\CompanyJob\pcbcart_html_cn\node_modules\readable-stream\lib\_stream_transform.js:172:83)
    at doWrite (H:\CompanyJob\pcbcart_html_cn\node_modules\readable-stream\lib\_stream_writable.js:428:64)
    at writeOrBuffer (H:\CompanyJob\pcbcart_html_cn\node_modules\readable-stream\lib\_stream_writable.js:417:5)
    at DestroyableTransform.Writable.write (H:\CompanyJob\pcbcart_html_cn\node_modules\readable-stream\lib\_stream_writable.js:334:11)
    at write (H:\CompanyJob\pcbcart_html_cn\node_modules\gulp\node_modules\readable-stream\lib\_stream_readable.js:623:24)
    at flow (H:\CompanyJob\pcbcart_html_cn\node_modules\gulp\node_modules\readable-stream\lib\_stream_readable.js:632:7)

Experiencing the same problem :/ So far can't find a fix for Gulp 3.9. Might have to upgrade to Gulp 4?

Hi @EthanOrange can you confirm if this issue still relevant using Gulp 4?

We no longer use wiredep, so the error should be gone and the HTML being emptied should not be an issue anymore. Maybe something caused wiredep to malfunction or their HTML comments weren't properly set up.

I'm closing this and will reopen if this is still an issue with the latest version of generator-webapp.