-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
fix(rest): correctly handle basePath set via basePath() API #3266
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's weird! Did you rebuild the entire monorepo? Here is how I am editing diff --git a/examples/todo/src/application.ts b/examples/todo/src/application.ts
index 9ee0dc68..566e3137 100644
--- a/examples/todo/src/application.ts
+++ b/examples/todo/src/application.ts
@@ -18,6 +18,8 @@ export class TodoListApplication extends BootMixin(
constructor(options: ApplicationConfig = {}) {
super(options);
+ this.basePath('/api');
+
// Set up the custom sequence
this.sequence(MySequence); And here is a screenshot from the API Explorer: @nabdelgadir can you try one more time please? |
89913aa
to
6ccf661
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
- Fix `server.basePath()` method to update `basePath` in the config object too. - This fixes the server url in openapi.json to include basePath again. - Add more test to verify the changes and prevent future regressions Signed-off-by: Miroslav Bajtoš <[email protected]>
6ccf661
to
c41a2fa
Compare
Hi @bajtos |
hi @raymondfeng , Server url like below(https://127.0.0.1/) https://user-images.githubusercontent.com/42985749/60344373-5efecb00-9984-11e9-8ca5-dd7d11ff0c98.png I need servers url like(https://127.0.0.1/api/) |
The feature should have been released for a while now. |
thank you @raymondfeng . Eagerly i am waiting for this feature. |
server.basePath()
method to updatebasePath
in the config object too.See #914
Checklist
👉 Read and sign the CLA (Contributor License Agreement) 👈
npm test
passes on your machinepackages/cli
were updatedexamples/*
were updated👉 Check out how to submit a PR 👈