Absolute imports/aliases for local plugins #28674
Unanswered
AustinLeeGordon
asked this question in
Help
Replies: 1 comment 3 replies
-
Have you tried using webpack aliases? Maybe using a plugin like this: https://www.gatsbyjs.com/plugins/gatsby-plugin-alias-imports/ |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Looking for a way to utilize absolute imports/aliases for local plugins like I can with components, pages, etc. May be some documentation out there, but I haven't been able to find anything. Tried using the custom config in
gatsby-node.js
and also triedbabel-plugin-module-resolver
.Use case: I share some utility functions between files in
src/
andplugins/
. I would like to keep them in a centralizedutils/
directory and import them easily with the same syntax.Beta Was this translation helpful? Give feedback.
All reactions