Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bundle with a npm package containing .cljs files #239

Closed
logseq-cldwalker opened this issue Jul 15, 2022 · 1 comment
Closed

Bundle with a npm package containing .cljs files #239

logseq-cldwalker opened this issue Jul 15, 2022 · 1 comment

Comments

@logseq-cldwalker
Copy link
Contributor

Hi @borkdude. I'm trying to convert https://github.com/logseq/graph-validator to use your new bundling work with a nodejs github action. Ran into this issue / feature request (not sure which). Cheers

Is your feature request related to a problem? Please describe.
I have a nbb{,-logseq} script which depends on cljs files in npm packages.
I tried to bundle with -cp but get this:

$ nbb-logseq -cp node_modules/@logseq/graph-parser/src:node_modules/@logseq/db/src bundle action.cljs -o out.mjs
Error: ENOENT: no such file or directory, open 'logseq/graph_parser/cli.cljs'
...

Since the repro above depends on nbb-logseq, here's a smaller nbb-only repro using the sitefox example:

$ nbb -cp node_modules/@chr15m/sitefox/src bundle webserver.cljs -o out out.mjs
Error: ENOENT: no such file or directory, open 'sitefox/web.cljs'
...

Does -cp just need to be ported over to bundle or is this pulling on something more involved from nbb.core?

Describe the solution you'd like
To be able to bundle a cljs file that depends on cljs files in npm packages

Describe alternatives you've considered
I could copy files out of node_modules to directories where bundle expects them but that seems pretty hacky

Additional context
n/a

@borkdude
Copy link
Collaborator

Gonna look into it. I think this falls under "enhancement" :)

borkdude added a commit that referenced this issue Jul 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants