swagger-api / swagger-api/swagger-codegen
[JavaScript] invokerPackage Config Parameter Not Functioning Properly
Nobody has claimed this yet.
- Dominant language
- Mustache
- Stars
- 17.8k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
Description
Using invokerPackage in a config file should result in setting the root path for the SDK. However, ApiClient.js and index.js are not moved into the root directory and remain in /src. As a result the entry point to the SDK ("main" in package.json) is set to /src/invokerPackage/index.js but index.js remains at /src.
Swagger-codegen version
Snapshot of 2.4.0
Steps to reproduce
- Create a JavaScript config file which has the invokerPackage parameter set
- Generate a JavaScript SDK with above config file
Contributor guide
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
Inspect the JavaScript generator's handling of the invokerPackage config alongside the generated ApiClient.js, index.js, and package.json. Reproduce SDK generation with invokerPackage set, then verify that the files are placed under the configured root and that package.json points to the resulting index.js.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100