- Here is a small excerpt from an array of objects utilized on my website. It's just a snippet and not the full JS file.
- I have several JS files like this, some reaching up to 500 lines of code.
- Currently delving into databases and APIs, I'm pondering whether storing this in something like MongoDB would be appropriate.
- The data isn't related to user information but rather gathered by me.
- Do databases serve a purpose solely for storing user data?
const pga = []
pga[0] = {
name: 'PGA',
job: 'T.J. Auclair',
date: '12 Aug 2018',
players: ['Jack Nicklaus', 'Tiger Woods', 'Bobby Jones',
'Walter Hagen', 'Sam Snead', 'Ben Hogan',
'Arnold Palmer', 'Gary Player', 'Gene Sarazen',
'Phil Mickelson', 'Tom Watson', 'Byron Nelson', 'Billy Casper',
'Seve Ballesteros', 'Harry Vardon'],
url: 'https://www.pga.com/news/golf-buzz/10-greatest-golfers-all-time',
pic: 'pga-com'
}