donpark / html2jade

Converts HTML to Jade template. Not perfect but useful enough for non-daily conversions.
MIT License
1.18k stars 156 forks source link

Does not work with html5boilerplate #23

Closed temsa closed 13 years ago

temsa commented 13 years ago
  1. Download a custom html5boilerplate with minified jquery and all the "other" column options checked, and unzip it in a folder
  2. in this folder, in command line, install your project as a global package sudo npm i -g html2jade
  3. html2jade index.html

Results in :

/usr/local/lib/node_modules/html2jade/lib/html2jade.js:333
      data = data.replace(/\s*\[if\s+[^\]]+\]>\s*/, '');
                  ^
TypeError: Cannot call method 'replace' of undefined
    at Converter.conditional (/usr/local/lib/node_modules/html2jade/lib/html2jade.js:333:19)
    at Converter.comment (/usr/local/lib/node_modules/html2jade/lib/html2jade.js:325:21)
    at Converter.<anonymous> (/usr/local/lib/node_modules/html2jade/lib/html2jade.js:309:23)
    at /usr/local/lib/node_modules/html2jade/lib/html2jade.js:3:63
    at Writer.forEachChild (/usr/local/lib/node_modules/html2jade/lib/html2jade.js:103:11)
    at Converter.children (/usr/local/lib/node_modules/html2jade/lib/html2jade.js:301:19)
    at Converter.element (/usr/local/lib/node_modules/html2jade/lib/html2jade.js:296:21)
    at Converter.<anonymous> (/usr/local/lib/node_modules/html2jade/lib/html2jade.js:305:23)
    at /usr/local/lib/node_modules/html2jade/lib/html2jade.js:3:63
    at Writer.forEachChild (/usr/local/lib/node_modules/html2jade/lib/html2jade.js:103:11)