
Product
Introducing Socket Firewall Enterprise: Flexible, Configurable Protection for Modern Package Ecosystems
Socket Firewall Enterprise is now available with flexible deployment, configurable policies, and expanded language support.
@crbroughton/nuxt-ignore-folders
Advanced tools
A simple Nuxt module that allows you to specify folders to ignore from the file-based routing system. By default, Nuxt's pages router includes all files in the pages directory, but sometimes you may want to keep other folders (like components, utils, etc.) in your pages directory without them becoming part of your routes.
npm install @crbroughton/nuxt-ignore-folders
Add the module to your nuxt.config.ts:
export default defineNuxtConfig({
modules: [
'@crbroughton/nuxt-ignore-folders'
],
// Module options
ignoreFolders: {
// Specify folders to ignore (replaces defaults)
folders: ['composables']
}
})
| Option | Type | Default | Description |
|---|---|---|---|
folders | string[] | ['assets', 'components', 'composables', 'layouts', 'middleware', 'plugins', 'public', 'server', 'shared', 'utils'] | Array of folder names to ignore from file-based routing. If you specify this option, it will replace the default list. |
This module hooks into Nuxt's pages:extend hook to filter out pages that match your ignored folder patterns. Any page with a file path containing /<folder>/ will be excluded from routing.
For example, if you set folders: ['components'], the following paths would be excluded:
/components/Button.vue/admin/components/Sidebar.vue/any/path/with/components/inside.vueBut these would still be included:
/component-demos/index.vue (not in a 'components' folder)/about/components-overview.vue (not in a 'components' folder)MIT
FAQs
Ignore folders from file-based router
We found that @crbroughton/nuxt-ignore-folders demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Socket Firewall Enterprise is now available with flexible deployment, configurable policies, and expanded language support.

Security News
Open source dashboard CNAPulse tracks CVE Numbering Authorities’ publishing activity, highlighting trends and transparency across the CVE ecosystem.

Product
Detect malware, unsafe data flows, and license issues in GitHub Actions with Socket’s new workflow scanning support.