next-gpa
v1.0.3
Published
Configures path aliases for all of the folders in your Next app.
Downloads
15
Readme
next-gpa (Generate Path Aliases)
Module path aliases are great for writing cleaner imports. You can read about them here in the Next.js docs. This package, next-gpa, configures them for you automatically.
Installation
(Global install recommended)
npm i -g next-gpa
Usage
In the root directory of your Next.js project, run npx next-gpa
. This will add every subdirectory contained in root directory as a module path alias.
Ignoring directories
By default, next-gpa ignores the following folders:
- node_modules
- dist
- build
- any folder that contains a "."
If you want to ignore additional directories, use add the --ignore
flag and list any directories after that.
npx next-gpa --ignore public styles utils