bencodezen / vue-enterprise-boilerplate

An ever-evolving, very opinionated architecture and dev environment for new Vue SPA projects using Vue CLI.
7.78k stars 1.32k forks source link

Sorry for such a NOOB question, but how would i go about orgnaizing the components into folders? #37

Closed ctwoodwa closed 6 years ago

ctwoodwa commented 6 years ago

I'm planning on having about 400 different pages within my app and I would like to organize the components into folders like components/base/_base++ and components/navbar/navbar vue files. I was able to move the navbar files to a folder, but i'm having an issue with the base files. after moving the base files to thier folder the tests no longer pass.

i tried changing the _globals.js to const requireComponent = require.context( // Look for files in the current directory './base', // Look in subdirectories false, // Only include "_base-" prefixed .vue files /_base-[\w-]+.vue$/ ) image

frandiox commented 6 years ago

@ctwoodwa You can check this fork. It places the components inside folders when you create them using yarn new 👍

chrisvfritz commented 6 years ago

Thanks @frandiox! I also provide a little more detail in this issue on why I organize components into a single folder. I'll consider this resolved for now, but happy to reopen if it's not. 🙂