Question: Cant Find Workbox File

Cant Find Workbox File

Hey, cant find and run npm run prod without workbox-config.js. Can u provide me this file?

GM

Gvidas Mikalauskas

Asked
Hey, cant find and run npm run prod without workbox-config.js. Can u provide me this file?
  • MS

    Mian Saleem

    Answered
    Hello,

    You can run `npm run build` The `workbox-config.js` will be deleted in the next update and will generate SW with Vitejs.

    If you need you can create file and these are the contents

    ```js
    module.exports = {
    globDirectory: './public',
    swSrc: 'public/sw-offline.js',
    swDest: 'public/service-worker.js',
    maximumFileSizeToCacheInBytes: 4194304,
    globPatterns: ['**/*.{js,html,css,png,jpg,gif,svg,eot,svg,ttf,woff,woff2}'],
    globIgnores: ['**/*.map', 'mix-manifest.json', 'manifest.json', 'service-worker.js'],
    };
    ```

    Thank you
  • GM

    Gvidas Mikalauskas

    Answered
    I did nothing to the code, but after i ran npm run build and added workbox-config.js I get this message:
  • MS

    Mian Saleem

    Answered
    What version are you using? Please try with v1.1.10
  • GM

    Gvidas Mikalauskas

    Answered
    im using v1.1.10
  • MS

    Mian Saleem

    Answered
    This version doesn't use any `require` statements. I am not sure why you are getting that error, it might be cache. Please try to clear browser cache and try again. Thank you
  • GM

    Gvidas Mikalauskas

    Answered
    Same error after cache clear. I downloaded it from codecanyon.net, maybe there is a problem.
  • GM

    Gvidas Mikalauskas

    Answered
    I saw that you updated codecanyon.net files, but still after running npm run build all i got is loading page and same Uncaught ReferenceError: require is not defined error
  • MS

    Mian Saleem

    Answered
    Please let me know your installation URL and server details in private reply. Thank you
  • GM

    Gvidas Mikalauskas

    Answered
    after i install composer require barryvdh/laravel-dompdf i get Class "Barryvdh\DomPDF\Facade\Pdf" not found. Maybe I need to register this somewhere to in your script?
  • MS

    Mian Saleem

    Answered
    Hello,

    Please refer to the package docs. As I know most of packages from Laravel v5.5 auto load the providers and facades.

    > Please be informed that we don't offer support for modification or modified versions. You are allowed to modify the item code at your own risk as per license.

    Thank you
  • Login to Reply