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

[Workshop] From API to UI: LoopBack with Angular with client generator #4849

Closed
4 tasks
dhmlau opened this issue Mar 10, 2020 · 12 comments
Closed
4 tasks

[Workshop] From API to UI: LoopBack with Angular with client generator #4849

dhmlau opened this issue Mar 10, 2020 · 12 comments

Comments

@dhmlau
Copy link
Member

dhmlau commented Mar 10, 2020

Since Angular is in TypeScript, it would be a good case to illustrate how to go from LoopBack to Angular.

With the same content, it can be used for:

  • Workshop material, e.g. NodeConf.EU, CASCON
  • Tutorial in LB4 docs or blog post

Acceptance Criteria

We can possibly use todo app as the base,

  • Create a working repo
    • generate the client using openapi-generator or ng-openapi-gen sdk
    • create a Angular frontend app for the todo APIs
  • Create an instruction maybe under page https://loopback.io/doc/en/lb4/Examples.html

Note:
@derdeka might have some recommendation on the sdk client to use. See his PRs loopbackio/loopback4-example-shopping#578 and loopbackio/loopback4-example-shopping#577

@dougal83
Copy link
Contributor

Plenty of avenues for adoption via https://openapi-generator.tech/docs/generators

@dhmlau
Copy link
Member Author

dhmlau commented May 23, 2020

Now that we have lb4 openapi --client, we should try to use this to generate the openapi client.

@madaky
Copy link
Contributor

madaky commented May 29, 2020

Please let me know if can contribute.
NodeConf.EU, CASCON : CfS closes at 9:00 AM 27 Jul 2020

@dhmlau
Copy link
Member Author

dhmlau commented May 29, 2020

You're more than welcome!

Now that we have the lb4 openapi --client option to generate the client, I'm thinking to:

  • use todo example as the starting example
  • generate the client
  • create a frontend application with Angular (i think a separate app is better).

I'm not sure if it's better to create a separate repo in the strongloop GH org as a standalone workshop material. @madaky @strongloop/loopback-maintainers, any thoughts?

@madaky
Copy link
Contributor

madaky commented Jun 1, 2020

Thanks @dhmlau . IMO, We should have a separate repo for workshop material. Which will help us better to track the work progress and specified material for workshop.
Also, I think the todo example is better to demonstrate with, but we should also include the RTS in todo example which will help user to get closer to the real benefits of powerful Framework.

@dhmlau
Copy link
Member Author

dhmlau commented Jun 2, 2020

IMO, We should have a separate repo for workshop material. Which will help us better to track the work progress and specified material for workshop.

+1. I can create a repo. Any suggestions on the name? loopback4-workshop-angular?

Also, I think the todo example is better to demonstrate with, but we should also include the RTS in todo example which will help user to get closer to the real benefits of powerful Framework.

What does RTS stand for? :). We have used https://developer.ibm.com/tutorials/create-rest-apis-minutes-with-loopback-4/ in the past for workshops. But this is pretty much the todo tutorial.

@madaky
Copy link
Contributor

madaky commented Jun 2, 2020

What does RTS stand for?

Oh sorry, actually , I mean to to say Real time Scenario/scene.
And for name my opinion is we can use name the repo as the purpose for which we are working on, which makes it specified, looback4--<?>.

@dhmlau
Copy link
Member Author

dhmlau commented Jun 10, 2020

@madaky, I've created this repo: https://github.com/strongloop/loopback4-workshop-angular.

@madaky
Copy link
Contributor

madaky commented Jun 11, 2020

@dhmlau
Copy link
Member Author

dhmlau commented Jun 11, 2020

@madaky, sorry about that. Didn't realize it was a private repo. I set the right access now. Please try again. Thanks.

@dhmlau dhmlau removed the 2020Q3 label Jul 28, 2020
@dhmlau
Copy link
Member Author

dhmlau commented Sep 28, 2020

@madaky, I used ng-openapi-api to generate the models and web client from the OpenAPI spec we got from LB app to Angular.
Here is my blog post: https://medium.com/@MobileDiana/building-a-frontend-application-with-loopback4-and-angular-e15c6fb48971
Here is my repo: https://github.com/dhmlau/loopback4-example-todo-angular

@dhmlau
Copy link
Member Author

dhmlau commented Nov 5, 2020

@dhmlau dhmlau closed this as completed Nov 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants