-
Notifications
You must be signed in to change notification settings - Fork 147
Set up a basic npm vue/webpack setup #6
Comments
Just to clarify: for the first pass we want to build the Vue project and have Django serve the static files? |
@excalliburbd check out the current template, it's already using Vue this way just as a demonstration |
I've been working on this issue, and I have a few questions.
By putting the assets outside the frontend project, at least one of webpack's handy features won't work. If we want to append a hash to the compiled frontend assets, so that browsers know when the production assets have been changed and need to be re-fetched, then we probably want to delete old compiled assets so they don't pile up. In order to use webpack's
|
My instinct is that this is fine since
This strikes me as correct. @lamby @pjbull thoughts?
Definitely. If the PR is accepted just reference @WGierke's work and you'll both get credit 👍 . Thanks for the thoughtful questions! |
For transparency and planning purposes, I am planning to start working on this issue over the weekend if it hasn't been addressed by then. 👀 |
Fixed in PR #97 thanks! |
Using the full power of webpack and Vue is indeed a good idea if possible. The best development experience would be being able to launch the webpack-dev-server locally and proxy the API calls to the backend. |
@Akryum That's how it works right now! |
Closing, as we now have this for local development. The full building of assets for "production" is being tracked in #136. |
Overview
We want to be able to use
.vue
files, ES6, and so forth.Expected Behavior
As a first pass, NdagiStanley/vue-django has a lot of what we want. At a minimum, we want to be able to build .vue files so that we can use ✨ ES6 :sparkles and have our project JS compiled, including
.vue
files.Design doc reference:
Technical details
vue-django
example is that we have two devservers (I think?) -- one from Django'smanage.py
and one from the JS setup.Acceptance criteria
.vue
(and other JS) assets, the output of which can be served by the Django processNOTE: All PRs must follow the standard PR checklist.
The text was updated successfully, but these errors were encountered: