GithubHelp home page GithubHelp logo

harleybalo / prisoner-content-hub-frontend Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ministryofjustice/prisoner-content-hub-frontend

0.0 1.0 0.0 14.26 MB

Front-end application for the Prisoner Content Hub

License: MIT License

Dockerfile 0.05% Makefile 0.04% JavaScript 88.96% CSS 1.37% Shell 0.01% HTML 4.35% SCSS 2.98% Gherkin 0.30% Mustache 0.13% Nunjucks 1.82%

prisoner-content-hub-frontend's Introduction

Digital Hub Frontend

The frontend for the Digital Hub service using Node

Getting started

Prerequisites

Node >= v10.15.3

Install dependencies

npm install

Running the application

Create a .env file using the provided template

cp .env-template .env

The .env can then be configured to point to local or remote backend services as required and toggle application features

Establishment from Hostname

The app now takes it's establishment name from the hostname of each request. In order for dev and staging sites to work we use a reg exp /-prisoner-content-hub.*$/g in order to only use the site name, i.e. production uses wayland. whereas staging uses wayland-prisoner-content-hub-staging.. The reg exp ensures wayland will be used in all cases.

Running tests

Jest is used for unit and integration tests

npm run test

Running the E2E tests

Cypress is used for E2E testing

Prerequisites

  • Backing services will need to be run in Docker-Compose using the prisoner-content-hub repository
  • Your /etc/hosts will need to be configured such that 127.0.0.1 localhost includes
    • wayland.prisoner-content-hub.local
    • berwyn.prisoner-content-hub.local
    • cookhamwood.prisoner-content-hub.local

To launch the application and open the Cypress test runner

npm run test:e2e:dev

To launch the application and run the Cypress tests

npm run test:e2e:run

prisoner-content-hub-frontend's People

Contributors

psoleckimoj avatar romidane avatar lucascairns avatar spikeheap avatar davidthomas22 avatar dependabot[bot] avatar

Watchers

James Cloos 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.