Description: A simple Node.js script that delivers a touch of enchantment by displaying a random fairy fact.
✨ Features
- Reads fairy lore from a
fairyfacts.txt
file. - Chooses a delightful fact at random.
- Prints the magical fact to the console.
⚙️ Setup
-
Prerequisites:
- Node.js installed on your system.
-
Create
fairyfacts.txt
:- Fill this file with enchanting fairy facts (one fact per line).
- You can find inspiration online or use your own imagination!
-
Save as
fairyfacts.js
:- Copy and paste the provided code into a file and save it as
fairyfacts.js
.
- Copy and paste the provided code into a file and save it as
🪄 Usage
-
Open your terminal or command prompt.
-
Navigate to the directory containing
fairyfacts.js
-
Execute:
node fairyfacts.js
A whimsical fairy fact will appear!