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

can nextjs be used in a non-javascript framework ? #1933

Closed
sandys opened this issue May 10, 2017 · 7 comments
Closed

can nextjs be used in a non-javascript framework ? #1933

sandys opened this issue May 10, 2017 · 7 comments

Comments

@sandys
Copy link

sandys commented May 10, 2017

hi guys,
nextjs is something that we have watched with a lot of excitement. However, the big issue we had was that our api stack is already in python+flask. We want to build several admin dashboards and we are seriously considering nextjs... but it is not obvious on how this will work.

is nextjs supposed to be used as the view layer of a non-javascript stack : say flask or rails ? Somewhat like this - https://realpython.com/blog/python/the-ultimate-flask-front-end/

or is it intended to be a javascript framework ?

@impronunciable
Copy link
Contributor

I don't know if I'm answering your question but next.js is not supposed to replace your backend. Next is a client-side framework that happens to have a server-side component to allow features like HMR and SSR. You can definitely combine it with your flask app.

@timneutkens
Copy link
Member

The best description to give Next.js is a frontend server. It can communicate with any backend using getInitialProps 😄 This is a good example: https://github.com/zeit/next.js/tree/master/examples/data-fetch

@sandys
Copy link
Author

sandys commented May 10, 2017 via email

@sandys
Copy link
Author

sandys commented May 10, 2017 via email

@impronunciable
Copy link
Contributor

@sandys exactly. You'll be able to use next export and just use it without the nodejs side. AFAIK there are people already using that branch

@timneutkens
Copy link
Member

Exactly like Dan said 👍

@rgbkrk
Copy link
Contributor

rgbkrk commented Jul 27, 2017

What would the best way to provide CSRF tokens and base URL to the next app? Query parameters?

@lock lock bot locked as resolved and limited conversation to collaborators May 11, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants