How can I require a html template with Browserify

前端 未结 2 1913
鱼传尺愫
鱼传尺愫 2021-02-20 10:03

I\'m trying to figure out an easy way to require a html template in the script and then run browserify from the CLI.

Say I want to grab a template and append it to the b

2条回答
  •  离开以前
    2021-02-20 10:31

    Good option is jstify.

    browserify ./app/main.js -t jstify > static/bundle.js
    

    For more information take a look this link

提交回复
热议问题