© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
SupabaseS
Supabase•4y ago
drewbie

Importing local code into Deno + Edge Functions

I am trying to import local code into an Edge function but I am not able to import anything that's outside of the /supabase directory.

I am using a monorepo for my app and have files outside of Supabase that would be nice to use for the function code. Importing code from within the supabase directory works just fine. I have a
_shared
_shared
directory within
functions
functions
that allows me to import local code (all with esh imports). However when I try to import something outside of the
supabase
supabase
directory, I get
TS2305 [ERROR]: Module '"deno:///missing_dependency.d.ts"' has no exported member foo
TS2305 [ERROR]: Module '"deno:///missing_dependency.d.ts"' has no exported member foo


Does every import coming into an Edge function need ESH imports? I think I may need to refactor my shared code to use esh imports vs using node_modules but wanted to see what I may be missing before headed down that route.

Any help is appreciated!
Supabase banner
SupabaseJoin
Supabase gives you the tools, documentation, and community that makes managing databases, authentication, and backend infrastructure a lot less overwhelming.
45,816Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Deno VS Code Intellisense for Edge Functions
SupabaseSSupabase / help-and-questions
3y ago
Edge functions + Deno Fresh?
SupabaseSSupabase / help-and-questions
4y ago
Issue with Deno Edge Functions: InvalidWorkerCreation when importing external modules
SupabaseSSupabase / help-and-questions
2mo ago
Authorization for Local Edge Functions
SupabaseSSupabase / help-and-questions
2w ago