dijs / wiki

Wikipedia Interface for Node.js
MIT License
315 stars 61 forks source link

page.content() weird output #102

Closed divanvb closed 5 years ago

divanvb commented 5 years ago

Hi

The content from the page is displayed very strangely. page = await wikijs({apiUrl:'https://cod-esports.gamepedia.com/api.php', }).page(OpTic_Gaming); console.log(await page.content());

Is there a way the function can be altared to return an array of objects with with the title & content of the information for example { title: Organization, content: 'OpTic Gaming is one of the more storied organizations within the competitive side of the Call of Duty franchise. The team was established in 2006 byOpTic KR3W for the aspirations of becoming a Call of Duty sniping team. Only leading OpTic for a short time, KR3W steps down and OpTic Jon3S, betterknown as OpTicJ, took his place. But J only lead the team for a very short time span as well, handed over the team to Hector “H3CZ” Rodriguez in 2007. H3CZ ran the team for two years before uploading their first video to YouTube in 2009. The same year OpTic Gaming started uploading to YouTube, H3CZ had established a Call of Duty competitive team that would become one of the teams with the biggest fan bases and presence in the community to ever play the game.'

Output:

OpTic Gaming is an American esports organization currently fielding teams in League of Legends, Overwatch, Gears of War, and Fortnite.

== History ==

=== Organization === OpTic Gaming is one of the more storied organizations within the competitive side of the Call of Duty franchise. The team was established in 2006 byOpTic KR3W for the aspirations of becoming a Call of Duty sniping team. Only leading OpTic for a short time, KR3W steps down and OpTic Jon3S, betterknown as OpTicJ, took his place. But J only lead the team for a very short time span as well, handed over the team to Hector “H3CZ” Rodriguez in 2007. H3CZ ran the team for two years before uploading their first video to YouTube in 2009. The same year OpTic Gaming started uploading to YouTube, H3CZ had established a Call of Duty competitive team that would become one of the teams with the biggest fan bases and presence in the community to ever play the game.

=== Modern Warfare 2 === OpTic Gaming’s pro team was established in 2010 with Nerve, Eaton, Di3seL and Gundeezy. They placed top four in their first event in the Frag Cup I.The team placed top eight in the MLG Online National Championship and then was able to close out the season with a 4th place finish at the MLG National Championship 2010.

=== Black Ops === Heading into Black Ops season, OpTic changed their roster completely. They picked up MerK, BigTymeR, Rambo and ProoFy. NaDeSHoT and JKap replaced Rambo and ProoFy going in the first major offline event of the year, MLG Dallas 2011. OpTic placed 3rd and then swapped out NaDeSHoT back for Rambo. This showed immediate dividends as the team won next event, MLG Columbus 2011. The team placed top four at the next two events before reaplacing Rambo with ProoFy going into MLG Orlando 2011. They won the tournament and then placed 3rd at the MLG National Championship 2011 to close out the year.

=== Modern Warfare 3 === With MLG not putting Modern Warfare 3 on the pro circuit, the team competed with various rosters at smaller LANs across the United States and Europe. After competing with apeX eSports NA during the spring, MerK, BigTymeR, Rambo and Scump joined OpTic for the remainder of the season. They won EGL 7 Blackpool and placed 2nd at EGL 8 Manchester. Rambo left OpTic to join Team EnVyUs and was replaced by NaDeSHoT to solidify a roster for the next year.

=== Black Ops 2 === OpTic Gaming was consistently one of the top teams during the Black Ops 2 season, but wasn't able to win another event after the first offline eventof the year, UMG Chicago 2012. They placed 5-6th at the MLG Winter Championship 2013 before taking 3rd at the next three events including the inaugural Call of Duty Championship. Looking to get back to the top, MerK was replaced by JKap. A 2nd placed finish at the MLG Fall Invitational rounded out the year.

=== Ghosts === At the beginning of Ghosts, the team started to fall short of top eight finishes at events, both online and offline.. After the MLG Fall Championship, JKap was dropped and OpTic Gaming picked up Ricky but that only lasted for one event. After UMG Philadelphia, BigTymeR announced that he would be retiring from competitive Call of Duty and coaching the OpTic Gaming squad. Following an avalanche of team changes, OpTic Gaming landed with NaDeSHoT, Scump, Clayster and MBoZe. The roster put OpTic Gaming back at the top as the placed 3rd at the Call of Duty Championship 2014. MBoZe left the teamafter the event to form a new OpTic Nation team and was replaced by ProoFy. The team won a gold medal at the MLG X Games Invitational 2014 and placed second at the MLG Anaheim 2014 International Playoffs but had an otherwise average season and placed top four or top six or worse in the last four events of the year.

=== Advanced Warfare === Less than a week after the release of Advanced Warfare, NaDeSHoT announced that Clayster and ProoFy were being released from OpTic Gaming as they picked up FormaL. A few days later, OpTic Gaming announced Crimsix would also be joining the team. The team won three out of the first five events of the year, but placed 7th at the Call of Duty Championship 2015. This poor placement pushed NaDeSHoT into retirement and allowed the team to add Karma from OpTic Nation. Due to his pending American citizenship application, Enable played for Karma at the next two European events, ESWC 2015 and Gfinity Spring Masters. Karma finally made his debut at UMG California 2015, which the team won. This roster would go on to win three of the final six events of the year, only placing second three times to Enable's FaZe Clan.

=== Black Ops 3 === The roster would stay the same going into the Black Ops 3 season. OpTic managed to qualify for the 2016 NA CWL Stage 1 Regular Season and won the Playoffs that followed. The team won Crown Melbourne Invitational, ESWC 2016 and MLG Anaheim Open 2016. After being upset at the 2016 NA CWL Stage 2 Playoffs, the team bounced back to win the MLG Orlando Open 2016 but once again failed to perform at the 2016 Call of Duty World League Championship byplacing 7-8th again.

=== Infinite Warfare === Infinite Warfare started slowly with the team placing 5-6th at the 2017 CWL Las Vegas Open. OpTic placed second at the 2017 CWL Atlanta Open and then won the 2017 CWL Paris Open and the 2017 CWL Dallas Open. These strong placements qualified them for the 2017 CWL Global Pro League Stage 1. The team placed 4th in the playoffs and 7-8th at the 2017 CWL Anaheim Open. With fans skeptical about the strength of the roster, OpTic Gaming finished theyear as the undisputed best team by winning the 2017 CWL Global Pro League Stage 2 and finally claiming victory at the elusive Call of Duty Championship.

=== WWII === Initially, the roster would stay the same going into the WWII season. However, with inconsistent placings at the first five Majors, with the most notable placing 13-16th at the 2018 CWL Seattle Open, plus placing 2nd at the Stage 1 playoffs in what will be known as one of the greatest grand finals chokes of all time, the highly decorated roster that were the best team in the world for nearly 3 1/2 years split up. Kicking FormaL and Karma and picking up Octane and Methodz didn't solve their tournament drought though. Their end of WWII saw them place 5-6th at the 2018 CWL Anaheim Open, 7-8th at the Stage 2 playoffs, and a shocking 17-24th at the 2018 CWL Championship. This was the first time since MW2 where OpTic failed to win a single championship title throughout a season.

== Timeline ==

== Player Roster ==

=== Active ===

=== Temporary Subs ===

=== Former ===

== Organization ==

=== Active ===

=== Former ===

== Trivia == Despite winning the majority of events in each Call of Duty title, the organization never won a Call of Duty Championship title. They finally won a Call of Duty Championship title by winning the 2017 Call of Duty World League Championship. Ever since FaZe Clan's roster of Clayster, Enable, ZooMaa, and Attach has formed in June 2015, OpTic's roster of Scump, FormaL, Crimsix, and Karma weren't able to defeat them on LAN. The losing streak began at UMG Dallas 2015. The streak finally ended when they matched up against FaZe for the 5thtime. They managed to beat FaZe 3-1 at 2017 CWL Atlanta Open. OpTic's former roster of Scump, FormaL, Crimsix, and Karma are the most winningest players in Call of Duty, with 32, 27, 24, and 20 championships respectively. OpTic was highly considered the best team in the Jetpack era of Call of Duty esports. OpTic's WWII season was the first time since MW2 where the organization failed to win a major championship.

== Team Achievements ==

== Media ==

=== Gallery ===

=== Articles ===

=== Interviews ===

=== Videos ===

=== Vision - Documentary Series ===

== External Links == OpTic Gaming: Defending the Throne - mlg.com

== References ==

dijs commented 5 years ago

Yeah, that's a good idea. I may be able to reuse some of the parsing I wrote for the tables.

dijs commented 5 years ago

This update will be a part of a major update.

Try it out @ v5.0.0-alpha.1

divanvb commented 5 years ago

Cool, will have a look.

divanvb commented 5 years ago

Seems to be working pretty well. Doesn't return all data in certain situations but I believe it's because the data is not of value type String.

So a bit of Array manipulation and boom bam everything I want.