JavaScriptファイルをwebpackで処理してみます。 1ファイルでの例 $ mkdir webpack_wk $ cd webpack_wk/ webpack で処理させるjsを作成します。 $ vi foo.js document.write(“Hello webpack”); foo.js から bundle.js を作成します。 $ webpack ./foo.js bundle.js bundle.jsを呼び出すHTMLファイルを作成します。 $ vi index.html <!doctype html> <html> <head> </head> <body> <script type=”text/javascript” src=”bundle.js” charset=”utf-8″></script> </body> </html> index.htmlをブラウザで表