🚀 This project is a single page application following the requirements and business rules proposed in technical challenge
The SPA must have:
A form (F1) with the following structure:
Contains a second form (F2) with the following structure:
Contains a table (T1) with the following columns:
The form F1 should accept json files with the following structure:
[
{
"extension": "java",
"count": 5000,
"filesize": 360
},
{
"extension": "xml",
"count": 3,
"filesize": 45.54
},
{
"extension": "xml",
"count": 14,
"filesize": 45
},
...
]
Once a valid file is selected and the user clicks on the button "Import", all the valid objects within the file should be added to the table "T1"
Once all fields in the form F2 are filled as valid and the user clicks on the button "Add", the valid object should also be added to the table "T1"
For each row, the "Action" should have an option link labeled "Delete" that, once clicked, will remove the corresponding row
The field "Extension" shall be unique, therefore only one row should be displayed on T1 for each extension type
Try to map as many error cases as possible within the SPA and display them for the user in a friendly manner
Opcional tasks not done:
1 - Clone this repository:
git clone https://github.com/adriatls/SPA-Svelte.git
2 - Install dependencies:
npm install
3 - Run the application:
npm run dev
1 - Pull my container from Docker Hub:
docker pull adriatls/adria-spa-web:latest
2 - Run the container:
docker run -d -p 3000:3000 adriatls/adria-spa-web
3 - In your browser: http://localhost:3000/
If you do not want to pull, it is possible to build and run the container locally
1 - Run the comand:
docker compose up -d --build --force-recreate
2 - In your browser: http://localhost:3000/