You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been using Bili for quite a few packages and it has worked well so far. We have our API, which uses ES6. It has a lot of index.js files, and we import them like so:
import resolvers from './resolvers'
And the resolvers/index.js is as follows:
import Query from './queries';
import Mutation from './mutations';
import types from './types';
export default {
Query,
Mutation,
...types
};
After the build, when I try running node build/server.js I get the error:
internal/modules/cjs/loader.js:638
throw err;
^
Error: Cannot find module 'resolvers'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
at Function.Module._load (internal/modules/cjs/loader.js:562:25)
at Module.require (internal/modules/cjs/loader.js:692:17)
at require (internal/modules/cjs/helpers.js:25:18)
at Object.<anonymous> (/Users/sam/Work/totem/systems/api/build/server.js:1:327)
at Module._compile (internal/modules/cjs/loader.js:778:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
Idk what I'm doing wrong here. I see you already have rollup-plugin-node-resolve included. I don't know why it's unable to find the file, and has not compiled it into the bundle.
Issue-Label Bot is automatically applying the label bug to this issue, with a confidence of 0.68. Please mark this comment with 👍 or 👎 to give our bot feedback!
Hey,
I've been using Bili for quite a few packages and it has worked well so far. We have our API, which uses ES6. It has a lot of
index.js
files, and we import them like so:And the
resolvers/index.js
is as follows:After the build, when I try running
node build/server.js
I get the error:Idk what I'm doing wrong here. I see you already have
rollup-plugin-node-resolve
included. I don't know why it's unable to find the file, and has not compiled it into the bundle.Here is my
bili.config.js
:Everything builds properly, but I can't run it.
Thanks!
The text was updated successfully, but these errors were encountered: