GithubHelp home page GithubHelp logo

photo-blog's Introduction

photo-blog

Material-UI based image blog powered by Gatsby. Live on blog.mohoff.de

Preview

Features

  • Gatsby generates various image representations of different resolutions and formats at build time. Per default, jpgs are converted to more space-efficient webp files and base64 image representations are generated. Both techniques helps fast and progressive loading of images with blur-effect.
  • No database required as image metadata is stored in sidecars.
  • Endpoint /random loads a random image on each page refresh.

Adding new photos

  1. Copy new images to /data
  2. Optional: Normlize new images
  3. Run yarn init, which create a sidecar (.md file) for each new image
  4. Edit the generated sidecars to add meta data such as title, tags, and a timestamp to your images

This process can be used for an empty and non-empty /data directory.

How to start

In development mode (hot reloading):

yarn start

In production mode:

yarn start:prod

Docker

The Dockerfile can be used to dockerize this app. Some useful commands:

docker build --tag index.docker.io/mohoff/photo-blog:latest .
docker push mohoff/photo-blog:latest
docker run -p 8000:8000 mohoff/photo-blog:latest

Testing and linting

yarn test
yarn lint
yarn lint:fix // Auto-fixes issues where applicable

photo-blog's People

Contributors

mohoff avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.