Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

where to find outputdir or dist-files when use "vue-cli-service serve"

When I run "vue-cli-service build" using npm or other, I can get a "dist" ouput dir which defined in vue.config.js.

    module.exports = {
      publicPath: '/',
      outputDir: 'dist',
    }

But, how can I find or where to find or how to defined the "dist" dir if I run "vue-cli-service serve"? I can't see any output dir in the project.

Needs help! Thanks

like image 670
W.X Avatar asked Sep 08 '19 06:09

W.X


People also ask

How do I check my vue-CLI-service?

You can access the binary directly as vue-cli-service in npm scripts, or as ./node_modules/. bin/vue-cli-service from the terminal. You can run scripts with additional features using the GUI with the vue ui command.

Where is the vue config js file?

vue. config. js is an optional config file that will be automatically loaded by @vue/cli-service if it's present in your project root (next to package. json ).

What is vue-CLI-service lint?

vue-cli-service lintLints and fixes files. If no specific files are given, it lints all files in src and tests , as well as all JavaScript files in the root directory (these are most often config files such as babel. config. js or .

Where is the webpack config file vue?

The webpack-simple template has the webpack-config. js file directly in root of your project folder. Looks like you are using webpack template. To make changes to the webpack config goto the build folder.


1 Answers

In development mode (the serve keyword) files are kept in RAM only - they are not persisted on the hard drive. If you are running the project at the default URL of http://localhost:8080 - then you should be able to see a listing of all the assets by going to http://localhost:8080/webpack-dev-server

There is a config option to ask the Webpack-dev-server to write files to disk -

webpack4: https://v4.webpack.js.org/configuration/dev-server/#devserverwritetodisk-

webpack5(should be): https://webpack.js.org/configuration/dev-server/#devserverdevmiddleware

like image 112
IVO GELOV Avatar answered Oct 02 '22 23:10

IVO GELOV