caffeinated / themes

:art: Laravel Themes package with support for the Caffeinated Modules package.

Home Page:https://caffeinatedpackages.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Theme isn't working with Module

davidweb-co opened this issue · comments

Hello,
I can't use this module https://github.com/caffeinated/modules
Module is return null value when use Theme::view, are you have solution?

Thank you

2015-03-12_10-08-52

commented

Should be:

return Theme::view('modules.yourmodule.your.view');

It's work, thank you.

clarification:

Theme::getActive() = bootstrap
'path' => public_path('themes'),

Currently it looks like when I do:

        return Theme::View('modules.general.landing');

the view comes from:
app/Modules/general/Resources/Views/landing.blade

I was hoping that the view would pull from:
public/themes/bootstrap/views/general/landing.blade

commented

Within your theme, you need to place it within a modules directory.

public/themes/bootstrap/views/modules/general/landing.blade
commented

Also, if the view file does not exist within your theme, it will fallback to using the view file supplied with your module.

Still not pulling from my theme directory.
Forward slashes don't work either and for some reason dd(Theme::all()) doesn't show in this controller however getActive() works.
IF I remove the view from the main modules directory I get the expected error response.

hmmmmmmm

Is there any way to debug this?

Never mind my previous post. Something weird is happening with my install. I deleted the package and reran composer and then deleted my config/themes file. Something must have gotten corrupted ...

Going to reopen this since issue is similar.

wanted location

public/themes/bootstrap/views/app.blade.php

view:

@extends('app')

When I'm trying to use my "default" I keep coming up with view not found. If I place that main "default" file within the resources/views directory I don't get the issue. Also, even if I do place a copy within my template directory the resource view is still being called.

Is this proper functionality?

commented

Gotta reference the theme namespace.

@extends('bootstrap::app')

ugh! facpalm 😵