Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php namespace Livewire\Tests; use Livewire\Component; use Livewire\Livewire; class Al..

Decoded Output download

<?php

namespace Livewire\Tests;

use Livewire\Component;
use Livewire\Livewire;

class AlpineIntersectBrowserTest extends \Tests\BrowserTestCase
{
    public function test_component_with_intersect_plugin_works()
    {
        Livewire::visit(new class () extends Component {
            public function render()
            {
                return <<<'HTML'
                <div x-data="{ inViewport: false }">
                    <div x-intersect:enter="inViewport = true" x-intersect:leave="inViewport = false">something</div>
                    <p x-text="inViewport ? 'in viewport': 'outside viewport'"></p>
                    <button type="button" dusk="button" wire:click="$refresh">refresh</button>
                </div>
                HTML;
            }
        })
            ->assertSeeIn('p', 'in viewport')
            ->waitForLivewire()->click('@button')
            ->assertSeeIn('p', 'in viewport');
    }
}
 ?>

Did this file decode correctly?

Original Code

<?php

namespace Livewire\Tests;

use Livewire\Component;
use Livewire\Livewire;

class AlpineIntersectBrowserTest extends \Tests\BrowserTestCase
{
    public function test_component_with_intersect_plugin_works()
    {
        Livewire::visit(new class () extends Component {
            public function render()
            {
                return <<<'HTML'
                <div x-data="{ inViewport: false }">
                    <div x-intersect:enter="inViewport = true" x-intersect:leave="inViewport = false">something</div>
                    <p x-text="inViewport ? 'in viewport': 'outside viewport'"></p>
                    <button type="button" dusk="button" wire:click="$refresh">refresh</button>
                </div>
                HTML;
            }
        })
            ->assertSeeIn('p', 'in viewport')
            ->waitForLivewire()->click('@button')
            ->assertSeeIn('p', 'in viewport');
    }
}

Function Calls

None

Variables

None

Stats

MD5 b0502ba83e7999b4a17f58b4f1049346
Eval Count 0
Decode Time 88 ms