fastnWith Django ..
.. or other backends.If your backend is written in Python/Django, Ruby On Rails, Java, Go etc, you can use
fastnto power the frontend of your application.
fastnin static site mode, then how the page looked when
fastn buildwas called will be shown to everyone. But if you are using dynamic mode then this page would be regenerated on every page load.
fastnIn The Front
fastnis being designed to be in the front of you backend application. The request from users browser first reach
fastn, and is then either handled by
fastnitself, say if it was for a static file, or for a route implemented by the
fastnacts as a proxy pass if you configure it like this:
-- import: fastn -- fastn.package: hello endpoint: https://127.0.0.1:8000
endpointtells you where the upstream server is. If
fastncan not serve an incoming request based on the content of the
fastnpackage, it will proxy the request to the provided
If your fastn package needs some data, direct SQL access does not work for you, you can use HTTP processor to make HTTP request to your backend, fetch data from your fastn document.This API call happens from server side, during the initial page generation.
If you want to call an API implemented in your backend, eg
https://127.0.0.1:8080/api/get-user if you have configured the
https://127.0.0.1:8080/, and your application is running on
fastn serve, you can make an API request to
and the request will go to
fastn first, and
fastn will forward the request
to your backend, and return the response returned by backend to the browser.
fastnacting as router, Nginx like proxy is not needed when doing local development.