symfony-rest-edition icon indicating copy to clipboard operation
symfony-rest-edition copied to clipboard

add Angular.js example?

Open lsmith77 opened this issue 10 years ago • 9 comments

Show up to combine Symfony2 with Angular.js. Show also how to setup security etc.

Potentially this should be a branch and not be merged into the main branch (aka 2.3)

lsmith77 avatar Aug 03 '14 15:08 lsmith77

Personally, I think this is a great idea because it seems like quite a common use-case.

weaverryan avatar Aug 04 '14 02:08 weaverryan

That would be incredible.

cbergau avatar Aug 05 '14 11:08 cbergau

What about writing a version of the profiler using AngularJS and consuming a REST API? Would be a great showcase.

pgodel avatar Aug 05 '14 16:08 pgodel

Huh, that's a really fun idea :).

This would also make a wonderful cookbook article. Perhaps code first, then some explanation of that code up at symfony.com. I'm really loving getting real examples and tutorial-style docs for common use-cases like this.

weaverryan avatar Aug 05 '14 17:08 weaverryan

LexikJWTAuthenticationBundle (https://github.com/lexik/LexikJWTAuthenticationBundle) do the job quite well. Are you interested in PR containing configurations of the bundle and/or Angular example?

drymek avatar Sep 04 '14 11:09 drymek

sure

lsmith77 avatar Sep 04 '14 11:09 lsmith77

would be nice to make links like https://github.com/bayne/symfony-angular-todomvc also into the article, they are clean implementations with variations :+1:

cordoval avatar Sep 04 '14 12:09 cordoval

Thus, except security configuration, such example exists. JWT is a good idea to secure API, but maybe it should be done as example application with link in README to symfony-angular-todomvc and symfony-rest-edition-jwt-example ? But in other hands it's quite ease to install a bundle (it has a doc...).

drymek avatar Sep 04 '14 12:09 drymek

as a showcase for #39 I will try to make a mock angular project as a separate repository, as long as https is used I think basic authentication is fine (which has the advantage to not need to reinvent the wheel) right ?

moreover if it's a full webapp reliyng 100% on the API, then as said, it may be better to simply do it a on a totally separate repository (so that you can always put it on a subdomain / other machine which leverage the fact that the angular code will 100% static files )

allan-simon avatar Oct 31 '14 15:10 allan-simon