Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-03-31 Thread Nathan Gaberel
Hi everyone, I've been working on this for a while too (for React & Webpack specifically) and will be sharing my current setup at DjangoCon Europe next week. For those of you attending, please come and talk to me, I'd love to get your feedback and maybe we can exchange ideas. :) Best, Nathan On

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-03-27 Thread Maciek Olko
Thank you all for all your responses! It's been a long time (sorry!), but: * I've added a Django ticket considering topic discussed here. [1] (* I updated a bit AJAX Django wiki page. [2]) Aymeric, in terms of copyright ownership, would you agree on rephrasing fragments of your articles to put it

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-27 Thread Jamesie Pic
FTR I published my own writeup here: https://blog.yourlabs.org/post/183077442308/django-js-research-report -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving e

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-25 Thread Jamesie Pic
On Mon, Feb 25, 2019 at 10:39 PM Jamesie Pic wrote: > component = dict( > template_name='django/forms/widgets/textarea.html', > script='your/textarea.js', > style='your/style.css' > ) Actually do NOT try this, for static i think the more efficient refactor would be to enable widgets a

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-25 Thread Jamesie Pic
Also in Django maybe try to change things like: class Textarea(Widget): template_name = 'django/forms/widgets/textarea.html' With component = dict( template_name='django/forms/widgets/textarea.html', script='your/textarea.js', style='your/style.css' ) Or something component='you

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-11 Thread Jani Tiainen
Hi, As we are heavy ExtJS and DojoToolkit users we've encountered quite a much problems since both frameworks do have their own toolchain and it doesn't seem to fit to webpack or rollup or anything like that. So if such a feature is planned for core I really hope that non mainstream tools are lef

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-10 Thread Josh Smeaton
For the vast majority of users, right now, Vue or React are the only real options. Let's not try predicting the future, and just focus on what the trends currently are. Users going for newer targets are likely more advanced, and can figure out the necessary changes. Aymerics articles are fantas

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-09 Thread Dmitriy Sintsov
Very nice tuturials! Although there is web components standard gradually being adapted by major browsers, which should bring custom tags / components not having to use the third party Javascript libraries like Vue or React. So, while in Python world the leadership of Django is quite stable and obvi

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-09 Thread Aymeric Augustin
Hello, I wrote a three-part essay on this question last year: 1. https://fractalideas.com/blog/making-react-and-django-play-well-together/ 2. https://fractalideas.com/blog/making-react-and-django-play-well-together-hybrid-app-model/ 3. https://fractalideas.com/blog/making-react-and-django-play-w

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-07 Thread Jamesie Pic
Well, there's also Graphene. It's at least REST or GraphQL. Le mar. 5 févr. 2019 à 03:09, Cristiano Coelho a écrit : > Pointing to Django Rest Framework should be more than enough. Anyone > starting a project with Django and a SPA/JS architecture, will pretty much > end up with DRF. Correct me i

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-06 Thread Dan Davis
The problem with ModelForm is translating validation to something front-end, like jquery Validator. Here, DRF does better, because swagger spec includes something like jsonschema (neither are a standard as I used to know them, in the WSDL/SOAP days), and so you can use jsonschema validation to va

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-06 Thread Dmitriy Sintsov
Speaking of Rails AJAX forms. It's quite trivial to submit Django ModelForm in Javascript AJAX request. It's a bit harder to have the customizable success action and to display the field validation errors via AJAX response. I implemented AJAX viewmodels for that: https://django-jinja-knockout.r

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-05 Thread Jamesie Pic
Throwing in some food for thought that may be worth mentioning and that we like to play with: - django-webpack-loader merged code chunking recently - transcrypt allows coding ie with react in Python, transcrypt also supports webpack - chp is a project that aims to replace templates as we know them

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-05 Thread Carlton Gibson
I think this topic is very interesting. Two sides of it: * Static files handling * APIs Curtis is right, there are other options but, Django REST Framework is (whilst not perfect) pretty solid on the API front. I think Django has a good story here. It's pretty hard not to find DRF if you fo

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-04 Thread ludovic coues
My current job is working on the django backend of a SPA/JS. Truth is, our django does not serve any JS file. The whole SPA is a bunch of static files, served by nginx. Every and only request with a path starting with /api are routed to Django. On Tue, Feb 5, 2019, 04:16 Curtis Maloney On 2/5/19

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-04 Thread Curtis Maloney
On 2/5/19 1:09 PM, Cristiano Coelho wrote: Pointing to Django Rest Framework should be more than enough. Anyone starting a project with Django and a SPA/JS architecture, will pretty much end up with DRF. Correct me if I'm wrong. It's likely they'd end up with DRF, however there are alternative

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-04 Thread Dan Davis
I kind of disagree that saying it works with DRF is enough. One issue that needs to be addressed is matching any possible path with re_path, so that an SPA that takes over the browser history API will work with bookmarks. Django is opinionated. The winning strategy for npm frameworks is to let t

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-04 Thread Jason Johns
Tom Christie wrote this about what DRF brings to the table over plain Django: Django REST framework isn't required, but it helps you get a lot of things right that will be time consuming and error prone if you're working from core Django. • Serializers The Django serializers are not really suit

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-04 Thread Cristiano Coelho
Pointing to Django Rest Framework should be more than enough. Anyone starting a project with Django and a SPA/JS architecture, will pretty much end up with DRF. Correct me if I'm wrong. El lunes, 4 de febrero de 2019, 19:52:42 (UTC-5), Maciek Olko escribió: > > I didn't find this topic being di

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-04 Thread Curtis Maloney
On 2/5/19 11:52 AM, Maciek Olko wrote: I didn't find this topic being discussed before. I guess it wouldn't take much to say "Just like any other server-side framework that can parse and generate arbitrary content, Django can be used to support any Javascript or Mobile app that talks HTTP(S)

Re: Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-04 Thread Kye Russell
Say what you want about the arguably unnecessary proliferation of complex JavaScript applications / build pipelines upon the Internet over the past 5 or so years, but there’s no denying it’s becoming a necessary component in a large portion of complex web projects. I also think that—if it hasn’t a

Extend FAQ with "How do I get Django and my JS framework to work together?"

2019-02-04 Thread Maciek Olko
I didn't find this topic being discussed before. It seems to me to be good idea to place "How do I get Django and my JS framework to work together?" or similar question and answer to it in FAQ in Django's docs. Having very big popularity of JS frameworks now it is indeed very common question bein