Sign inSign up

gprakosa/csv2html

By gprakosa

Updated over 3 years ago

Image
0

477

gprakosa/csv2html repository overview

Docker Image based on Derek Eder's Github Repository (all credits belong to him) with some features!.

Version

v1.7
  • add spinner on loading
v1.6
  • add capability for regex filter
  • add capability for styling rows based on a column condition
v1.5
  • add capability for download as filtered
v1.4
  • add capabilty for select multiples CSV within data folder
v1.3
  • add capabilty for sorting date time using Moment.js
v1.0 - 1.2
  • add capability for setup via environment variables
  • add capability for fixed header
  • add capabilty for filter on each columns

Run

Docker
docker run -d --rm -it --name csv2html \
-e APP_TITLE="Player Stats" \
-e APP_LOGO_URL="https://upload.wikimedia.org/wikipedia/id/thumb/e/e3/2022_FIFA_World_Cup.svg/220px-2022_FIFA_World_Cup.svg.png" \
-e APP_ORG="FIFA World Cup" \
-e APP_YEAR="2022" \ 
-e APP_DESC="Source: kaggle.com" \
-e APP_CSV_COL_HIDE="3,9,12,13,14,17,18,19,20,21,22,23,24,25,26,27,28,29,30" \
-e APP_CSV_FILELIST=1 \
-e APP_CSV_ROW_SPOT="data[0] == 'Cristiano Ronaldo'" \
-p 30003:8000 gprakosa/csv2html:v1.7

You can also mount your own filesystem and use it as follows

…
-v $PWD:/app/data
-e APP_CSV_FILENAME=“<your-csv-filename>”
…

Environments

ParameterVariableDefault ValueNotes
Application PortAPP_PORT8000
Application TitleAPP_TITLE"CSV to HTML Table"
Application Logo URLAPP_LOGO_URL-
Application OrganizationAPP_ORG-automatically add "at"
Application YearAPP_YEAR-automatically add "©"
Application DesciptionAPP_DESC-
Application Stylesheet URLAPP_STYLE_URLBootstrap URL
Appliction Font-FamilyAPP_STYLE_FONT"Arial,sans-serif"
Application CSV FilenameAPP_CSV_FILENAME"player_stats"just without .csv
Application CSV ListAPP_CSV_FILELIST0available: 0, 1
Application CSV Column to Sorted-byAPP_CSV_COL_SORT"0, 'asc'"available: asc, desc
Application CSV Column to HideAPP_CSV_COL_HIDE-use comma for multiple columns
Application CSV Column Date FormatAPP_CSV_COL_DATE-use Moment.js format
Application CSV Rows to SpotAPP_CSV_ROW_SPOT"col[0] == ''"use any Javascript conditional statement
Application CSV Rows to Spot ClassAPP_CSV_ROW_SPOTCLASS"text-warning bg-dark"

Tag summary

Content type

Image

Digest

sha256:b5762b3a2

Size

20.8 MB

Last updated

over 3 years ago

docker pull gprakosa/csv2html:v1.7