star-planet-table

This package renders a table listing stars and planets with user interaction using Evergreen package

Usage no npm install needed!

<script type="module">
  import starPlanetTable from 'https://cdn.skypack.dev/star-planet-table';
</script>

README

Playfusion start-planet table

Build Status

This is a RESTful application built for Disruptional with a star look-up table with searching, sorting and filtering functionality.

The URL will change based on each functionality to provide users convenience to share the search results.

This repository is configured to be CI/CD on Heroku with a custom domain www.zhaolingyun.me.

Instructions

A star look-up table with searching, sorting and filtering functionality.

Instructions

Here is an example of the details card and an illustration for table footer with pagination and information about the current page.

Card and pagination


The APIs I used for each functionality are:

Table header/content props structure

Table information is passed by an array of objects, named as tableHeader, including mandatory entries type, title, width and dataParam. For example:

[
         {type: `sort`, title: `name`, dataParam: `name`},
         {type: `sort`, title: `radius`, dataParam: `radius`},
         {type: `sort`, title: `age`, dataParam: `age`},
         {type: `sort`, title: `mass`,  dataParam: `mass`},
         {type: `sort`, title: `number of planets`, dataParam: `numberOfPlanets`}
]

Run it on your browser

Use Webpack-Dev-Server:

npm install
npx webpack-dev-server -d

Run tests manually on your local machine

This repository is using Travis CI. Once all tests passed, master branch will be continuous deployed on Heroku.

Use the following command to run local tests with an updating snapshots option.

npm test -- -u