File structure for nuxt 2 and bem scss/sass
nuxt-project/
├─ assets/
│ ├─ scss/
│ │ ├─ base/ # Base styles (e.g., resets, typography)
│ │ ├─ components/ # Component-specific styles
│ │ ├─ layout/ # Layout-specific styles
│ │ ├─ mixins/ # SCSS mixins
│ │ ├─ variables/ # SCSS variables
│ │ └─ main.scss # Main SCSS file
│ └─ ...
├─ components/ # Reusable Vue components
│ └─ ...
├─ layouts/ # Layout components
│ └─ ...
├─ pages/ # Route-specific Vue components
│ └─ ...
├─ plugins/ # Nuxt plugins
│ └─ ...
├─ static/ # Static files (e.g., images, fonts)
│ └─ ...
├─ store/ # Vuex store files
│ └─ ...
├─ nuxt.config.js # Nuxt configuration file
└─ package.json # Project dependencies and scripts
assets
directory holds your SCSS files. Within the scss
directory, you can create separate subdirectories for different types of styles, such as base
, components
, layout
, etc. The main.scss
file is the entry point for your styles and should import all other SCSS files.components
directory contains Vue components that are reusable across different pages and layouts.layouts
directory holds layout components that define the structure of your pages.pages
directory includes route-specific Vue components. Each file in this directory corresponds to a route in your application.plugins
directory is used to store Nuxt plugins, which can be used to add global functionality to your application.static
directory is meant for static files such as images, fonts, and other assets that you want to serve directly.store
directory is used for managing application state using Vuex.