Programatic use: Allow string input
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 9.8k
- Forks
- 326
- PR merge metrics
- No merged PRs in 30d
Description
According to the examples provided in the readme and the examples folder, ncc always expects a path to a file.
In my use case, I'd prefer to directly take a string input e.g.:
const src = "console.log(require("hello-world-npm").helloWorld());";
const bundled = ncc(src);
Is this of interest to be implemented? If so, can you recommend an API definition. I'd be happy to take over the work myself. Please let me know. Thanks
Potentially related:
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the README's “Programmatically from Node.js” section and the examples folder to understand the current path-based API. Then identify the programmatic entry point and decide on a documented API for string input; done means the API is settled and string-based bundling works as described.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- api, tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100