Landlosen Svelte Themes

Landlosen

Svelte-app for retrieving country information through restcountries.com. Screenshots provided in README.md at the end.

Landlosen

Image credits:
Texture image: Reto Stöckli, NASA Earth Observatory
Normal map image: Imagery by Jesse Allen, NASA's Earth Observatory, using data from the General Bathymetric Chart of the Oceans (GEBCO) produced by the British Oceanographic Data Centre

What is this

Landlosen is a solution to the assignment for candidates for internship at SmartGIS.

It is not meant to be used as a stable source of information, but to be used as a basis for a technical interview for applicants to a job position.

What does Landlosen mean?

Landlosen is Norwegian and is put together from two words, "land" and "los". "Land" means both country and land, and "los" means guide or navigator. Landlosen can be translated to "country guide", which is what this service does through the RestCountries API.

Table of Contents

Task description

This is not provided here, due to it being a time-limited task which is likely the same as other interviewees get. Therefore it is withheld by me.

How to run

Manually

  1. From your wanted folder to run it from, open a terminal and enter:

    git clone https://github.com/Scandiking/Landlosen
    
  2. Then unzip the folder to wanted location.

  3. cd to that location. Example:

    cd C:/Users/YourName/ThisDownload
    
  4. If the terminal now says something like

    C:/Users/YourName/ThisDownload>
    
  5. Then you can write

    npm run dev
    
  6. And now it should open in your standard browser.

If you are not used to using the terminal, you can do it the point-and-click-way:

Using the provided .bat-file

  1. Download the .zip directly from here or click the green Code-button on this page and click Download ZIP in the dropdown menu.
  2. Download and unzip it to wanted location.
  3. Double-click the RUN_ME.bat file.

Extra features

  • Søke etter land i søkeboks
  • Velge språk; norsk eller engelsk
    • Reaktiv lasting av språkstrenger, ingen ny sidelasting nødvendig
    • RestCountries inkluderer ikke norske oversettelser i sine endpoints, så det som GET-es er på engelsk. Det tilbys likevel noen lokale oversettelser i dette prosjektet, men denne listen er ikke endelig. Litauen blir for eksempel Litauen, mens Elfenbenskysten forblir Ivory Coast...
  • RestCountries har ikke translation for norske egennavn på land, dette finnes i countries.ts.
  • Velge temamodus; systemmodus, mørk modus eller lys modus
  • Custom scrollbar (kun i WebKit-baserte nettlesere, Gecko-baserte nettlesere reverter til default og har få tilpasningsmuligheter uansett)

Notes

This is running locally, from your machine, but reading data from RestCountries. That means if that site is down, which is likely due to their capacity worries, you won't be able to get any results, and just browse a "shell" without any content.

  • Det er en del blanding av norsk og engelsk.

  • Flowbite component library var ikke så greit å jobbe med, derfor er det skrevet egne løsninger innimellom for større detaljkontroll...

  • CSS burde vært global, men er per-page for øyeblikket.

Screenshots

Landing page with countries retrieved from RestCountries' all endpoint in light mode.

The page for retrieving information for a single country in light theme.

The page for listing all countries, and the option to sort by name, population, area, and region in light mode.

Landing page with countries retrieved from RestCountries' all endpoint in dark mode.

The page for retrieving information for a single country in dark theme.

The page for listing all countries, and the option to sort by name, population, area, and region in dark mode.

Top categories

Loading Svelte Themes