Skip to content

Commit

Permalink
fix!: use new blade service (#7)
Browse files Browse the repository at this point in the history
  • Loading branch information
thorbrink authored Feb 20, 2024
1 parent 6252ae6 commit a7ae239
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions Public.php
Original file line number Diff line number Diff line change
@@ -1,18 +1,16 @@
<?php

use ComponentLibrary\Init as ComponentLibraryInit;
use HelsingborgStad\GlobalBladeService\GlobalBladeService;

if (!function_exists('modularity_products_render_blade_view')) {
function modularity_products_render_blade_view($view, $data = [], $compress = true)
{
$init = new ComponentLibraryInit([
$bladeEngine = GlobalBladeService::getInstance([
MODULARITY_PRODUCTS_MODULE_VIEW_PATH
]);

$bladeEngine = $init->getEngine();

try {
$markup = $bladeEngine->make(
$markup = $bladeEngine->makeView(
$view,
array_merge(
$data,
Expand Down

0 comments on commit a7ae239

Please sign in to comment.