Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    codemonkeynorth
    @codemonkeynorth
    Looking to see if I have an example with svg in
    codemonkeynorth
    @codemonkeynorth
    But for now you can just import in your main index to test
    Alexander
    @xenx-efy
    ok, thx
    codemonkeynorth
    @codemonkeynorth
    On a side note. If you’re using an external svg as an img src, some servers require the xml/doctype header . Let me find example
    Alexander
    @xenx-efy
    that would be nice.
    codemonkeynorth
    @codemonkeynorth
    I had to add this...
    <?xml version="1.0" encoding="utf-8"?>
    <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
    <?xml version="1.0" encoding="utf-8"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
    Take the space out. Should be a line break
    I’m not sure related to your issue though
    Are you using latest wpemerge version?
    Alexander
    @xenx-efy
    I think so.
    in composer.json written last
    codemonkeynorth
    @codemonkeynorth
    Check this patch is applied htmlburger/wpemerge-theme#59
    That appears to be your exact problem
    codemonkeynorth
    @codemonkeynorth
    What is @last? Did you mean @latest ? I never use it to be honest
    Maybe I’m thinking of something else
    Alexander
    @xenx-efy

    Check this patch is applied htmlburger/wpemerge-theme#59

    You’re awesome, it helps. You made my day)

    I found several changes between my version and current in github. I don't know why. Furthermore, I installed it from docs instruction.
    codemonkeynorth
    @codemonkeynorth
    Ah good!
    Sorry just to clarify, I add “assets” into the bundles array in config.json. I then create a resources/scripts/assets/index.js file where I do my imports of asset files I want to reference in php
    codemonkeynorth
    @codemonkeynorth
    The webpack process will add the images to the manifest etc but the main js file for the site does not need to increase in size because of the imports (although I’m not sure it would anyway as it’s only an import reference)
    Basically it’s a dummy unused js file , that’s just there to make sure my image references exist
    Alexander
    @xenx-efy
    ok, got it
    2pi.pl
    @piotrk_twitter
    Did anybody tried to compare the performance of a similar website based on a plain Wordpress installation vs WP Emerge?
    Here we have everything nicely set up for the developer with routing, view, controllers, composers but I'm wondering at what cost?
    What could be the bottleneck here?
    Atanas Angelov
    @atanas-dev
    Hypothetical bottlenecks aren't really that helpful or addressable. In my testing, WP Emerge did not add any significant overhead in terms of execution time or memory use.
    If there is a real life reproducible performance issue then I would consider it a bug that needs to be fixed :)
    WP Emerge's integration is also incremental so you can only apply it to certain routes rather than all requests, for example.
    Arthos
    @taliesinpenbardd

    @peter-brennan I managed to reproduce the issue and crate a fix. Could you please follow these steps to make sure the fix works for you:

    1. Edit composer.json and change "htmlburger/wpemerge-blade": "^0.16.0" to "htmlburger/wpemerge-blade": "dev-master#e40a42010809c6cb0911cb4f5d6e68ef21f1f36f as 0.16.0"
    2. Run composer update htmlburger/wpemerge

    hey all, I did try this but since i'm using wpemerge-theme v0.16.2 and wpemerge-blade v0.16.1, this doesn't seem to work anymore. Blade bits in my /woocommerce/archive-product.php file are not rendered, just showed. any idea on how to make Woocommerce use Blade ? Thanks by advance

    Atanas Angelov
    @atanas-dev
    The file must be .blade.php in order for Blade to consider it a Blade template - try renaming it.
    Arthos
    @taliesinpenbardd
    will try that, i referred to the https://github.com/htmlburger/wpemerge-blade doc which mentioned that files must not named .blade.php :)
    Atanas Angelov
    @atanas-dev
    Ah, then that's misleading - I'll take a look.
    Arthos
    @taliesinpenbardd
    so, i gave it a try, and /woocommerce/archive-product.php is interpreted but blade is not recognized, when /woocommerce/archive-product.blade.php is not seen by WP, and we fall back on the default woocommerce template...
    Atanas Angelov
    @atanas-dev
    Are you sure you've followed all of the setup steps e.g. adding the Blade service provider to your config?
    Arthos
    @taliesinpenbardd

    in config.php :

            \DomaineLesCanons\WordPress\WoocommerceServiceProvider::class,
            \WPEmergeBlade\View\ServiceProvider::class,
    [...]
        /**
         * Other config goes after this comment.
         */
        'replace_default_engine' => true,
        'proxy_php_views' => true,
        'filter_core_templates' => true,
        'options' => [
            'views' => [ get_stylesheet_directory(), get_template_directory() ],
            'cache' => ABSPATH . '/wp-content/uploads/wpemerge/cache/blade',
        ]

    i guess i'm good, am i not?

    Atanas Angelov
    @atanas-dev
    These need to be under a 'blade' key - see the example under "You can change these options by specifying a blade key in your WP Emerge config array:" in the Blade extension readme.
    Arthos
    @taliesinpenbardd
        /**
         * Other config goes after this comment.
         */
        'replace_default_engine' => true,
        'proxy_php_views' => true,
        'filter_core_templates' => true,
        'blade' => [
            'options' => [
                'views' => [ get_stylesheet_directory(), get_template_directory() ],
                'cache' => ABSPATH . '/wp-content/uploads/wpemerge/cache/blade',
            ],
        ],
    this doesn't seem to change anything. i erased the /uploads/wpemerge/cache folder, but after recreation, it fills with files from the template (sidebar, walker, header, footer, etc) but no woocommerce template
    Atanas Angelov
    @atanas-dev
    All of them need to be under 'blade' - not just options
    /**
     * Other config goes after this comment.
     */
    'blade' => [
        'replace_default_engine' => true,
        'proxy_php_views' => true,
        'filter_core_templates' => true,
        'options' => [
            'views' => [ get_stylesheet_directory(), get_template_directory() ],
            'cache' => ABSPATH . '/wp-content/uploads/wpemerge/cache/blade',
        ],
    ],
    Arthos
    @taliesinpenbardd
    ok, that works, i missed that part. according to the doc, the file doesn't have to be .blade.php, only .php and that works now. thanks !