Bagisto Forum

    Bagisto

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups

    how can i edit velocity theme

    Knowledge Base
    7
    11
    1774
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • F
      farshadf last edited by

      i wonder to know how can i edit velocity theme as long as it has resource in 2 places 1 in packages and 1 in themes/velocity
      i want to know if i make changes to themes folder and if i compile or npm run watch in future will that changes be overwritten ?? thanks

      1 Reply Last reply Reply Quote 0
      • shubhwebkul
        shubhwebkul last edited by

        Hello there,
        there will be two scenarios.
        1 - If you want to edit blade file you need to change files under resources directory. If you are making changes in files under Velocity package, so you need to publish your blade files everytime to reflect your changes.

        2 - Next scenario will be if you want to make changes view vue components, you just to install dependencies in velocity package and execute command npm run watch. Your changes should reflect from this.

        Feel free to ask further queries!
        thanks & regards,
        Shubham Mehrotra

        A K 3 Replies Last reply Reply Quote 0
        • A
          agampradhana last edited by

          hi,

          npm run watch

          @ watch /Users/agampradhana/Desktop/projects/bagisto
          npm run development -- --watch

          @ development /Users/agampradhana/Desktop/projects/bagisto
          cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js "--watch"

          sh: cross-env: command not found
          npm ERR! file sh
          npm ERR! code ELIFECYCLE
          npm ERR! errno ENOENT
          npm ERR! syscall spawn
          npm ERR! @ development: cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js "--watch"
          npm ERR! spawn ENOENT
          npm ERR!
          npm ERR! Failed at the @ development script.
          npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
          npm WARN Local package.json exists, but node_modules missing, did you mean to install?

          npm ERR! A complete log of this run can be found in:
          npm ERR! /Users/agampradhana/.npm/_logs/2020-05-26T08_32_35_331Z-debug.log
          npm ERR! code ELIFECYCLE
          npm ERR! errno 1
          npm ERR! @ watch: npm run development -- --watch
          npm ERR! Exit status 1
          npm ERR!
          npm ERR! Failed at the @ watch script.
          npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
          npm WARN Local package.json exists, but node_modules missing, did you mean to install?

          npm ERR! A complete log of this run can be found in:
          npm ERR! /Users/agampradhana/.npm/_logs/2020-05-26T08_32_35_355Z-debug.log

          1 Reply Last reply Reply Quote 0
          • shubhwebkul
            shubhwebkul last edited by

            Have you installed dependencies by executing npm i command ?

            1 Reply Last reply Reply Quote 0
            • A
              Aung Myo Oo @shubhwebkul last edited by

              @shubhwebkul
              I edit the shopping.blade.php and then I run the php artisan vendor:publish but not reflected my chnages

              1 Reply Last reply Reply Quote 0
              • devansh-webkul
                devansh-webkul last edited by

                Hi @Aung-Myo-Oo,

                If you have not customized anything then you can run,
                php artisan vendor:publish --force

                Otherwise, I will suggest you place that file manually in the resources/themes path.

                P 1 Reply Last reply Reply Quote 0
                • K
                  Kaalee @shubhwebkul last edited by

                  @shubhwebkul Assume we edited all layout structure blade files in velocity theme suppose we want to update future patchwork then can we able to update without losing my exiting velocity theme change?

                  1 Reply Last reply Reply Quote 0
                  • K
                    Kaalee @shubhwebkul last edited by

                    This post is deleted!
                    1 Reply Last reply Reply Quote 0
                    • devansh-webkul
                      devansh-webkul last edited by

                      Hi @Kaalee,

                      If you are doing inside the Velocity package, then in the future if some updates on the package came then it will be tough for you to remove the conflicts.

                      The suggested way is always to use the resources/ folder and take a backup of that folder from time to time. So that if mistakenly force published then you can replace it with your backup.

                      And for code like controller, helpers, etc. Always try to override the classes in your app directory.

                      1 Reply Last reply Reply Quote 1
                      • P
                        Praveenkumar @devansh-webkul last edited by

                        @devansh-webkul
                        After I customized the header and some pages in the theme and Run this command php artisan vendor:publish --force all my changes are gone. Is there any way to revive back the code?

                        1 Reply Last reply Reply Quote 0
                        • devansh-webkul
                          devansh-webkul last edited by

                          @devansh-webkul said in how can i edit velocity theme:

                          Hi @Aung-Myo-Oo,

                          If you have not customized anything then you can run,
                          php artisan vendor:publish --force

                          Otherwise, I will suggest you place that file manually in the resources/themes path.

                          I already mentioned here that if you have not customized then you can run it.

                          Now there is no way.

                          1 Reply Last reply Reply Quote 0
                          • First post
                            Last post