This Site

11/23/2015

You are currently viewing my site on a NEF Stack server, Node, Express, Firebase. Node and Express are used for the backend and Firebase for the data. It is also hosted via heroku

Firebase is an amazing database system, it’s more of a BaasS (Backend as a service) as it offers user auth as well as data. It’s main focus is realtime data, however that is not a feature I used in this site. I used Firebase as I was familIar with it’s API and I find it very easy to use, the user auth was also very useful as I only need one account it seemed a bit silly to spend time building a custom user auth system.

Posts are formatted using Markdown, I chose to use it because I have experience using it and it’s very easy to work with, it’s popularity also means there are many libaries to render it. For this site I used markdown-it.

I used the templating engine, nunjucks by mozilla. I would’ve used swig, however that has been deprecated. Nunjucks is based on the python templating language, Jinja 2. Here is a sample of the code:

<h1>{{ title }}</h1>

<ul>
{% for item in array %}
<li>{{item}}</li>
{% endfor %}
</ul>

Using a templating language allows a base layout to made and helps with keeping to the D.R.Y. principle. (D on’t R epeat Y ourself).

For post comments I used disqus, this is because it’s widely used and very esy to implement

Finally I used stormpath to make a contact form. This allows users to fill out a form and email me, without giving out my email.



Copyright Emily Peregrine © 2015
Admin Log In