Skip to content

justLiberals/justliberals-barn

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

justLiberals barn

The justLiberals barn is where all the assets are kept.

Why?

Assets for various parts of justLiberals were kept across a few places, and it was hard to track. It's also hard to on-board new people when you need to start with a map of where everything is (there was also a small amount of copy-paste engineering going on between repositories..).

Although it would be possible to split out some of these assets, keeping them all in one place makes it clear and easy to understand where everything is kept - in the barn!

What?

These are the things currently in the barn:

Websites (under websites/)

justLiberals hosts the following websites:

These are static websites, built using the Eleventy static site generator from templates written in Nunjucks that are based on Bootstrap. Currently the website sources articles from a Ghost instance. We avoid cookies, JavaScript and third party assets - see below for details.

You can spin up a version of the website using npm start, but first you'll have to add the GHOST_CONTENT_API_KEY as an environment variable. This will start a local copy of both justLiberals.org.uk (on port 8081) and aldes.org.uk (on port ``8082`). See below for more information about contributing.

Emails (under emails/)

justLiberals sends both transactional emails and newsletters, which are kept under their namesake directories. TEXT versions of emails are written in Jinja; HTML emails are built in mjml (which is then compiled to Jinja on deployment). These are deployed to our Meadow instance, which uses them for our newsletters.

You can see your mjml changes live with their app, or their plugins for VS Code and Atom.

Articles

Coming soon

Why don't you use Cookies/JavaScript/Trackers/etc?

justLiberals is a project formed and focused around Liberalism - as such, it's obvious to us that Liberalism should be baked into our offerings. We do not currently have a functional need for Cookies or JavaScript, so we don't use them. We also don't consider it right to track visitors to our websites or consumers of our content, so we don't do that either. The only data we have is what CloudFront (our CDN provider) logs, and although we do also keep an eye on Google Search Console - to see what people are searching for when they land up on our website - we don't use Google Analytics, Facebook Pixel or any other third party tracker.

Note: while we have principles, we are not blind to nuance or necessity - if we build something that requires a cookie, or some browser-based JavaScript, we will use it. There's nothing inherently wrong with these tools - we just don't need them right now.

I'd like to contribute

Awesome! You can clone this repository, install Node.js, run npm install from within the directory and you're off to the races.

Step-by-step

Want some more guidance? Follow these steps:

  1. Install Visual Studio Code, which we will use for editing files.
  2. Install Git. If you're using the installer then select "Use Visual Studio Code" as the default editor. Leave all other settings as their defaults.
  3. Install the LTS edition of Node.js - note that if you're doing this on Windows, be sure to check the box to "Automatically install the necessary tools" (this is going to take a while, and open up a few different Command and PowerShell windows in the process). Leave all other settings as their defaults.
  4. Open Visual Studio Code and click "clone repository...". A box will open at the top, to which you should copy and paste the HTTPS URL for this repository (https://github.com/justLiberals/justliberals-barn.git). Then press enter.
  5. VS Code will ask you where you want to put the repository - the default is fine, so click "Select Repository Location". Then click "Open" in the box on the bottom-right.
  6. You now have a directory tree on the left of all the files and folders in the repository.

Website contributions

  1. Click "Terminal" on the menu bar, then "New Terminal" to open a terminal window.
  2. Type npm install, then once that's done type npm start.
  3. You can now browse to:
  • http://localhost:8081/ to find a local instance of justLiberals.org.uk
  • http://localhost:8082/ to find a local instance of aldes.org.uk Both sites will reload whenever you make a change in their respective subdirectories under websites/

Email contributions

  1. Go to the "Extensions" tab (the three blocks + one block on the left hand side) and type mjmlio.vscode-mjml in the search bar at the top. Then click "Install" next to the MJML item.
  2. Once this has finished installing, go back to the file browser (the document on the left-hand side) and open emails/transactional/validate_HTML.j2.mjml.
  3. Click the red mjml icon on the top right and a rendering of the mjml tempate will be presented to you.

This gives an overview of how you can contribute, but feel free to ask questions in the #jl-project channel on the Discord for more information.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •