Git Product home page Git Product logo

Comments (5)

igaster avatar igaster commented on July 4, 2024

Cloning a theme is as easy as making a copy of the views+assets folders and updating the theme.json file to point to the correct asset location. In what scenario would you prefere to clone a theme instead of extending it? Extending a theme will come with the benefit of staying always synced when for example the parent themes updates a js library or fixes a css error etc...

However It wouldn't be difficult to implement. I could put it on the roadmap :-)

from laravel-theme.

GaalexxC avatar GaalexxC commented on July 4, 2024

You're right it can done simply by making copies of those directories and renaming, lol, just as a developer who has pulled out many hairs over the years I strive for simplicity and running one command to do it is sweet to me. Also I am currently implementing this app into the database (caching templates, user theme select, and rebuilding views, etc), it reflects work I have done on IPB which can do everything in your command console from the admin panel with a click or two. Anyone whos used software like that knows the benefits of this method. Its not adding a great new feature but more of how easy can I make this work...

No need to stress over it Ill work it up and post, if you deem it beneficial then be my guest and use it.

One thing I am having difficulty with is my vendor views in my theme, its not showing my apps vendor folder views but the 3rd party vendor directory views and thats not working nicely in my app. I think it may be a path issue, sure Ill figure it out, I still have a few hairs left.

Thanks for the great app.

from laravel-theme.

igaster avatar igaster commented on July 4, 2024

Yesterday I added some documentatin about vendor paths, it might help. I have build an application for testing which covers many scenarios which I plan to publish soon,

Tip: If you want to debug themes, a quick way to display the Laravel's search paths (for views only) is:

dd(app()->make('view.finder')->getPaths())

from laravel-theme.

GaalexxC avatar GaalexxC commented on July 4, 2024

Great! Ill have a look

from laravel-theme.

GaalexxC avatar GaalexxC commented on July 4, 2024

I added the debug line in my admin app layout and got the following

array:3 [▼
  0 => "/path_to/resources/views/smarty/smarty"
  1 => "/path_to/resources/views/smarty"
  2 => "/path_to/resources/views"
]

My theme is obviously named smarty. Is this proper behavior to show smarty/smarty in the array?

BTW the app I am using is arcanedev/Log-Viewer for admin side logs. The only relevant settings are in the log-viewer config

    /* -----------------------------------------------------------------------------
     |  Route settings
     | ------------------------------------------------------------------------------
     */
    'route'         => [
        'enabled'    => true,

        'attributes' => [
            'prefix'     => 'admin/log-viewer',

            'middleware' => ['web', 'admin'],
        ],
    ],

Path to log viewer views is

/resources/views/smarty/vendor/log-viewer

Everything else works fine

from laravel-theme.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.