/**
  * @param $version
  * @param $package
  * @param $page
  *
  * @return \Illuminate\View\View
  */
 public function show($version, $package, $page)
 {
     if ($version === 'current') {
         $version = $this->repository->getLatestVersion();
     }
     $content = $this->repository->findForVersion($version, $package, $page);
     if (!$content) {
         throw new NotFoundHttpException();
     }
     $title = $this->getPageTitle($content);
     $index = $this->repository->getIndex($version, $package);
     return view('docs', ['version' => $version, 'package' => $package, 'page' => $page, 'title' => $title, 'content' => $content, 'index' => $index]);
 }
 /**
  * @param $version
  * @param $package
  * @param $page
  *
  * @return array
  */
 public function findForVersion($version, $package, $page)
 {
     return $this->cache->remember($version . $package . $page, 60, function () use($version, $package, $page) {
         return $this->repository->findForVersion($version, $package, $page);
     });
 }
 /**
  * @param $version
  * @param $package
  * @param $page
  *
  * @return array
  */
 public function findForVersion($version, $package, $page)
 {
     $content = $this->repository->findForVersion($version, $package, $page);
     return $this->converter->text($content);
 }