S
S
SeokkyN2018-10-30 01:21:32
webpack
SeokkyN, 2018-10-30 01:21:32

Laravel + Vue: Why does webpack throw chunks in the public root?

I will be brief.
Snippet from routes.js:

const AdminLogin    = () => import ('../components/admin/Login.vue')
const AdminMain     = () => import ('../components/admin/Main.vue')
const AdminStudents = () => import ('../components/admin/Students.vue')
const AdminTeachers = () => import ('../components/admin/Teachers.vue')
const AdminGroups   = () => import ('../components/admin/Groups.vue')
const AdminTests    = () => import ('../components/admin/Tests.vue')

The problem is that the sliced ​​chunks go straight to the public root.
5bd787a5d7153036090763.png
In fact, there are 6 of them, 12 pieces - a consequence of my attempts to figure out the problem on my own.
The question is, how can I configure the path for unloading these chunks myself? For example, in js/chunks.
Senks.
PS: I tried to google in the direction of __webpack_require__.p, however, the situation could not be corrected.
UPD: still relevant.

Answer the question

In order to leave comments, you need to log in

9 answer(s)
S
skepsikmod, 2019-04-16
@skepsikmod

In webpack.mix.js add

mix.webpackConfig({
  output: {
    path: path.resolve(__dirname, 'public/'),
    publicPath: '/',
    chunkFilename: './js/[id].chunk.js'
  }
})

E
Evgeny Elchev, 2015-09-09
@rsi

Java Philosophy

O
Oleg Gamega, 2015-09-09
@gadfi

java is any book, android needs the basics. OOP , collections
, basic syntax and I highly recommend these two articles it) here everything is very accessible even with minimal knowledge of English www.vogella.com/tutorials/android.html
and yes a lot of practice))

D
Dmitry, 2015-09-09
@Dit81

Herbert Schildt "Java 8. The Complete Guide 9th Edition". A lot of code examples, everything is available, if there is a base, then that's it!
I also recommend Horstmann K., Cornell G. "Java. The Professional's Library. Volume 1. Fundamentals. Ninth Edition". Just mega-useful for a Java coder!

A
Andrey Nikiforov, 2015-09-08
@eoffsock

For general features of the language, one usually reads Head First Java and Schildt's Java, A Beginner's Guide.
Related links: https://plus.google.com/+KevinDarty/posts/Qex6Ae6zhZW
For Android: developer.android.com/index.html
Dev Guiges and developer.android.com/develop/index.html

L
Lici, 2015-09-09
@Lici

Since the creation of hello-word. Books later.

R
ruslanys, 2015-09-17
@ruslanys

Not a book, of course, but a very good site: javarush.ru

V
Vasilij Aleksashin, 2015-09-10
@TerraMorf

Any book for learning English!

A
advirtys, 2015-09-18
@advirtys

Head First learn java then java philosophy then do a study project e.g. write a copy of the notepad

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question