Closed KenEucker closed 4 years ago
There is one web endpoint for the Reddit template, located at http://biketag.org/get/reddit.
Another ancillary update here: With the implementation of ejs templating in the app, we can more easily support this feature request.
Specifically, starting with the /get/reddit endpoint, it should be rewritten as an ejs view that is served instead of the raw HTML being compiled by the appcode.
Following up on the last comment. The /get/reddit endpoint now serves via an ejs template. Closing this issue for now, as previous experiments using SSR and Hypernova were unnecessary and bloated.
What We could do serverside rendering for any kind of template and then those can sit at a JSON endpoint, that the app then consumes. The first two templates to build are the
postedTagTemplate
and theredditPostTemplate
. These endpoints will receive a POST request with some data and return the template with the data, the template without the data, and the data inside a JSON object.Why The templates for data on the biketag site shouldn't be in the templates for the sites, let's put them into their own templated endpoints and allow for different views of the same data. This also allows us to get templates based on our data to do migrations and historical post imports more simply.
How Use a templating engine? Output can be any text whether it be html or not.