|
@@ -18,4 +18,24 @@ class CostcoController
|
|
|
</script>';
|
|
|
}
|
|
|
}
|
|
|
+ public function serviceWorker()
|
|
|
+ {
|
|
|
+ $content = view('service-worker.file', [
|
|
|
+ 'filesToCaches' => [
|
|
|
+ '/storage/costco/register-serviceworker.js',
|
|
|
+ '/storage/costco/costco-icons.woff',
|
|
|
+ '/storage/costco/logo.png',
|
|
|
+ '/storage/costco/avatar.jpg',
|
|
|
+ '/storage/costco/bar.png',
|
|
|
+ '/storage/costco/menu.jpg',
|
|
|
+ '/storage/costco/480.png',
|
|
|
+ '/storage/costco/JsBarcode.all.min.js',
|
|
|
+ '/costco/',
|
|
|
+ ]
|
|
|
+ ]);
|
|
|
+ $response = \Response::make($content);
|
|
|
+ $response->header('Content-Type', 'application/javascript; charset=utf-8');
|
|
|
+
|
|
|
+ return $response;
|
|
|
+ }
|
|
|
}
|