search

Home  >  Q&A  >  body text

javascript - Directory structure issue officially provided by vue

After starting the service, you will see that the page source code is like this

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title>my-vue-project</title>
  </head>
  <body>
    <p id="app"></p>
    <!-- <p id="luffy"></p> -->
    <!-- built files will be auto injected -->
  <script type="text/javascript" src="/app.js"></script></body>
</html>

, it should be generated through webpack, but I can’t find the generated file. Where is it? If you develop under this official directory, you should publish the webpack package when publishing the project, but what if the packaged index.html and app.js are not found? ? Please help~~The path of webpack configuration is under the dist directory, but dist is not found. Please explain!

滿天的星座滿天的星座2826 days ago652

reply all(3)I'll reply

  • 过去多啦不再A梦

    过去多啦不再A梦2017-05-19 10:43:49

    1. You will not be able to find this file when npm run dev starts the service locally.
    2. The file path after executing npm run build and packaged can be viewed in config/index.js

    reply
    0
  • phpcn_u1582

    phpcn_u15822017-05-19 10:43:49

    npm run buildIt’s ready in no time.

    reply
    0
  • 滿天的星座

    滿天的星座2017-05-19 10:43:49

    npm run dev does not generate files by default.
    npm run build will generate the dist directory by default

    reply
    0
  • Cancelreply