1.0.1 • Published 4 years ago

polar-bear-facts v1.0.1

Weekly downloads
9
License
-
Repository
-
Last release
4 years ago

polar-bear-facts

This package returns facts about polar bear. If you would like to add more facts go to the facts.json file and add more. When adding more facts make sure to add them with he same format and credit the source.

Functions

  • randomFact
  • fact(num)
  • factList

Reference

      "http://www.softschools.com/facts/animals/polar_bear_facts/32/",
      "https://www.wwf.org.uk/learn/fascinating-facts/polar-bears",
      "https://owlcation.com/stem/Interesting-Facts-About-Polar-Bears",
      "https://www.natgeokids.com/uk/discover/animals/general-animals/polar-bear-facts/",
      "https://www.livescience.com/27436-polar-bear-facts.html",
      "https://kidzone.ws/sg/polarbear/polar_bear.htm"

    

Returns

randomFact

{
   "number": 45,
   "fact": "Their fat not only keeps polar bears warm, it also increases their buoyancy when they swim.",
   "source": "https://www.livescience.com/27436-polar-bear-facts.html"
}

fact(42)

{
   "number": 42,
   "fact": "Although good swimmers, polar bears aren’t quick enough to reliably catch seals in open water. Instead, they depend on the ice as a hunting platform.",
   "source": "https://www.natgeokids.com/uk/discover/animals/general-animals/polar-bear-facts/"
}

factList

[
   {
      "number": 0,
      "fact": "Polar bears are largest species of bears.",
      "source": "http://www.softschools.com/facts/animals/polar_bear_facts/32/"
   },
   {
      "number": 1,
      "fact": "Polar bears are the largest land predators.",
      "source": "http://www.softschools.com/facts/animals/polar_bear_facts/32/"
   },
   {
      "number": 2,
      "fact": "Polar bears live in Arctic region of Russia, Alaska, Canada, Greenland, and Norway",
      "source": "http://www.softschools.com/facts/animals/polar_bear_facts/32/"
   },
   {
      "number": 3,
      "fact": "Due to their large size, they have no natural enemies, except humans.",
      "source": "http://www.softschools.com/facts/animals/polar_bear_facts/32/"
   },
   
   ... // continues to fact 50
   
    {
      "number": 50,
      "fact": "Polar bear fur is oily and water repellent. The hairs don't mat when wet, allowing the polar bears to easily shake free of water and any ice that may form after swimming. ",
      "source": "https://kidzone.ws/sg/polarbear/polar_bear.htm"
   },
   {
      "number": 999,
      "reference": [
         "http://www.softschools.com/facts/animals/polar_bear_facts/32/",
         "https://www.wwf.org.uk/learn/fascinating-facts/polar-bears",
         "https://owlcation.com/stem/Interesting-Facts-About-Polar-Bears",
         "https://www.natgeokids.com/uk/discover/animals/general-animals/polar-bear-facts/",
         "https://www.livescience.com/27436-polar-bear-facts.html",
         "https://kidzone.ws/sg/polarbear/polar_bear.htm"
      ]
   }
]