Skip to content

Morning-Train/LaravelReact

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Laravel React

React for Laravel

Install

Via Composer

$ composer require morningtrain/laravel-react

Usage

View

In your controller:

return view('your_view')->with([
    'component' => 'Welcome',
    'props'     => [
        'title' => 'From controller',
    ],
    'options'   => [],
]);

And in your view:

@react()

Or straight from view:

@react([
    'component' => 'Welcome',
    'props' => [
        'title' => 'From view',
    ],
    'options' => [],
])

Credits

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •