Giter VIP home page Giter VIP logo

furnace's Introduction

๐Ÿ”ฅ Furnace

Melts down the GOLD ( Design System ) components into a zip file.

The furnace is an express server that allows users to easily get started with the Australian Government Design System. The furnace dynamically builds zip files based on each selected component and options that are sent to the server.

Install

npm install
npm run build

Then run npm start or npm watch to start the server.

Getting started

Once the server is started it can now take POST requests at the URL http://localhost:8080/furnace/. The POST requests are in the form of:

{
	components: [ 'accordion', 'breadcrumbs' ],
	styleOutput: 'css',
	jsOutput: 'js',
}

The above POST would return a zip file containing minified css and js for all of the dependencies of accordion and breadcrumbs.

components

An array of components that relates to the currently live components in the GOV.AU Design System.

styleOutput

  • css: css minified
  • cssModules: css modules for each component
  • sassModules: sass modules for each component

jsOutput

  • js: js minified
  • jsModules: js modules for each component
  • react: react modules for each component

Testing

To test that the furnace is working run npm run test. This runs a unit test against the functions making sure the output is correct. It also runs an integration test making sure that a mock zip file is downloaded and has the correct output.

You can also manually test the furnace by sending a POST to the local instance.

  • Install the dependencies npm install
  • Starting the furnace npm run watch
  • Send a POST to the furnace while it is running using curl:
curl -d "components=accordion&components=breadcrumbs&styleOutput=css&jsOutput=js" http://localhost:8080/furnace >> designsystem.zip

Changelog

  • v1.0.0 - Initial version of the furnace

furnace's People

Contributors

dominikwilkowski avatar sukhrajghuman avatar pattyde avatar azerella avatar

Watchers

napstar 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.